]> git.ipfire.org Git - thirdparty/tar.git/commitdiff
Fix minor diagnostic discrepancies in incrementals
authorPaul Eggert <eggert@cs.ucla.edu>
Thu, 15 Aug 2024 06:05:33 +0000 (23:05 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Thu, 15 Aug 2024 06:25:46 +0000 (23:25 -0700)
* src/incremen.c (read_directory_file, get_gnu_dumpdir):
Be more consistent about fatal errors.

src/incremen.c

index 41dd0d86e9b0355fbd23d4c335f367978f440e6e..0654e1550fd17de3e6e176bc9456f51061618e1f 100644 (file)
@@ -1349,16 +1349,17 @@ read_directory_file (void)
        {
          ebuf = buf + sizeof PACKAGE_NAME - 1;
          if (*ebuf++ != '-')
-           ERROR((1, 0, _("Bad incremental file format")));
+           FATAL_ERROR ((0, 0, _("Bad incremental file format")));
          for (; *ebuf != '-'; ebuf++)
            if (!*ebuf)
-             ERROR((1, 0, _("Bad incremental file format")));
+             FATAL_ERROR ((0, 0, _("Bad incremental file format")));
 
          ebuf++;
          if (! ('0' <= *ebuf && *ebuf <= '0' + TAR_INCREMENTAL_VERSION
                 && !c_isdigit (ebuf[1])))
-           ERROR ((1, 0, _("Unsupported incremental format version: %s"),
-                   ebuf));
+           FATAL_ERROR ((0, 0,
+                         _("Unsupported incremental format version: %s"),
+                         ebuf));
          incremental_version = *ebuf - '0';
        }
       else
@@ -1482,7 +1483,7 @@ get_gnu_dumpdir (struct tar_stat_info *stat_info)
       mv_size_left (size);
       data_block = find_next_block ();
       if (!data_block)
-       ERROR ((1, 0, _("Unexpected EOF in archive")));
+       FATAL_ERROR ((0, 0, _("Unexpected EOF in archive")));
       copied = available_space_after (data_block);
       if (copied > size)
        copied = size;