]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
maint: pacify ‘make syntax-check’
authorPaul Eggert <eggert@cs.ucla.edu>
Mon, 6 Mar 2023 23:37:45 +0000 (15:37 -0800)
committerPaul Eggert <eggert@cs.ucla.edu>
Mon, 6 Mar 2023 23:39:07 +0000 (15:39 -0800)
Problem reported by Pádraig Brady (Bug#61386#226).
* src/split.c (parse_chunk): Use die instead of error.
(main): Quote a string.
* tests/local.mk (all_root_tests): Move du/apparent.sh from here ...
(all_tests): ... to here.

src/split.c
tests/local.mk

index cc581b6c65651416563e67f4d7a5ac547d235a31..95d174a8b42e4b344d5dddb87183504391f0c255 100644 (file)
@@ -1325,8 +1325,8 @@ parse_chunk (intmax_t *k_units, intmax_t *n_units, char const *arg)
       *n_units = parse_n_units (argend + 1, "",
                                 N_("invalid number of chunks"));
       if (! (0 < *k_units && *k_units <= *n_units))
-        error (EXIT_FAILURE, 0, "%s: %s", _("invalid chunk number"),
-               quote_mem (arg, argend - arg));
+        die (EXIT_FAILURE, 0, "%s: %s", _("invalid chunk number"),
+             quote_mem (arg, argend - arg));
     }
   else if (! (e <= OVERFLOW_OK && 0 < *n_units))
     strtoint_die (N_("invalid number of chunks"), arg);
@@ -1561,7 +1561,7 @@ main (int argc, char **argv)
 
   if (n_units == 0)
     {
-      error (0, 0, _("invalid number of lines: %s"), "0");
+      error (0, 0, _("invalid number of lines: %s"), quote ("0"));
       usage (EXIT_FAILURE);
     }
 
index 1fe04235d03e81ab94bf11ac7b09cfce5bb0bf3a..1e93290d02fef642717b0250634d83e807446a36 100644 (file)
@@ -118,7 +118,6 @@ all_root_tests =                            \
   tests/dd/skip-seek-past-dev.sh               \
   tests/df/problematic-chars.sh                        \
   tests/df/over-mount-device.sh                        \
-  tests/du/apparent.sh                         \
   tests/du/bind-mount-dir-cycle.sh             \
   tests/du/bind-mount-dir-cycle-v2.sh          \
   tests/id/setgid.sh                           \
@@ -557,6 +556,7 @@ all_tests =                                 \
   tests/df/total-verify.sh                     \
   tests/du/2g.sh                               \
   tests/du/8gb.sh                              \
+  tests/du/apparent.sh                         \
   tests/du/basic.sh                            \
   tests/du/bigtime.sh                          \
   tests/du/deref.sh                            \