From 254d4ba3ea82abd597e2f7b0814c29aeb47dace2 Mon Sep 17 00:00:00 2001 From: "B. Watson" Date: Sat, 6 Dec 2025 06:57:05 -0500 Subject: unalf -v: Don't show header lines if file isn't an ALF file. --- src/listalf.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/src/listalf.c b/src/listalf.c index 6fb26fc..054fe36 100644 --- a/src/listalf.c +++ b/src/listalf.c @@ -77,13 +77,14 @@ void list_alf(void) { char buf[100]; extern char *out_filename; - if(opts.verbose_list) { - puts("Name Size was Size now Comp Date Time CkSum"); - puts("============ ======== ======== ==== =========== ========= ====="); - } - while(read_alf_header()) { c++; + + if(opts.verbose_list && c == 1) { + puts("Name Size was Size now Comp Date Time CkSum"); + puts("============ ======== ======== ==== =========== ========= ====="); + } + orig_size = getquad(alf_hdr_origsize0); comp_size = getquad(alf_hdr_compsize0); out_filename = (char *)(mem + alf_hdr_filename); -- cgit v1.2.3