diff options
| author | B. Watson <urchlay@slackware.uk> | 2025-12-07 02:29:59 -0500 |
|---|---|---|
| committer | B. Watson <urchlay@slackware.uk> | 2025-12-07 02:29:59 -0500 |
| commit | 2718ebef0c3a1dcaab74b567ba5726a9fa20fcdb (patch) | |
| tree | 77813a70af69b85969df346c5c4466d00fec7050 | |
| parent | 32b66419b8137e18ec949093d507bf29c8528d7d (diff) | |
| download | alftools-2718ebef0c3a1dcaab74b567ba5726a9fa20fcdb.tar.gz | |
alf -vv: say "Created" if trying to append to a file that doesn't exist.
| -rw-r--r-- | src/alf.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -236,6 +236,9 @@ void crunch_file(const char *filename_arg) { perror(out_filename); exit(1); } + /* so -vv will correctly say "Created" if trying to append to + a non-existent file. */ + if(ftell(out_file) == 0) opt_append = 0; } if(fwrite(output_buf, 1, output_len, out_file) < 0) { |
