diff options
author | Ruediger Meier | 2017-06-20 20:01:32 +0200 |
---|---|---|
committer | Ruediger Meier | 2017-06-22 21:51:40 +0200 |
commit | 05691d9e8857de4e83b343f042e9f4590f15425d (patch) | |
tree | 81b958bbfba5cd68ba91881fae6208393c042608 | |
parent | build-sys: update DISTCHECK_CONFIGURE_FLAGS (diff) | |
download | kernel-qcow2-util-linux-05691d9e8857de4e83b343f042e9f4590f15425d.tar.gz kernel-qcow2-util-linux-05691d9e8857de4e83b343f042e9f4590f15425d.tar.xz kernel-qcow2-util-linux-05691d9e8857de4e83b343f042e9f4590f15425d.zip |
misc: fix some broken exit codes
These tools have special exit codes. They got changed mistakenly.
See:
findfs 0e1fa6b6
fsck 658c0891
fsck.cramfs 922ec175
mkfs.cramfs 16154b1f
tunelp 2ab428f6
FIXME: STRTOXX_EXIT_CODE doesn't work as it should.
Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
-rw-r--r-- | disk-utils/fsck.c | 2 | ||||
-rw-r--r-- | disk-utils/fsck.cramfs.c | 2 | ||||
-rw-r--r-- | disk-utils/mkfs.cramfs.c | 2 | ||||
-rw-r--r-- | misc-utils/findfs.c | 4 | ||||
-rw-r--r-- | sys-utils/tunelp.c | 5 |
5 files changed, 9 insertions, 6 deletions
diff --git a/disk-utils/fsck.c b/disk-utils/fsck.c index cb1b21278..5a418fc1f 100644 --- a/disk-utils/fsck.c +++ b/disk-utils/fsck.c @@ -55,7 +55,7 @@ #include "fileutils.h" #include "monotonic.h" -#define STRTOXX_EXIT_CODE FSCK_EX_ERROR +#define STRTOXX_EXIT_CODE FSCK_EX_USAGE #include "strutils.h" #define XALLOC_EXIT_CODE FSCK_EX_ERROR diff --git a/disk-utils/fsck.cramfs.c b/disk-utils/fsck.cramfs.c index 63033d626..952f15332 100644 --- a/disk-utils/fsck.cramfs.c +++ b/disk-utils/fsck.cramfs.c @@ -671,7 +671,7 @@ int main(int argc, char **argv) break; case 'V': printf(UTIL_LINUX_VERSION); - return EXIT_SUCCESS; + return FSCK_EX_OK; case 'x': opt_extract = 1; if(optarg) diff --git a/disk-utils/mkfs.cramfs.c b/disk-utils/mkfs.cramfs.c index 77b4467e7..041c6d74e 100644 --- a/disk-utils/mkfs.cramfs.c +++ b/disk-utils/mkfs.cramfs.c @@ -910,5 +910,5 @@ int main(int argc, char **argv) (warn_namelen|warn_skip|warn_size|warn_uid|warn_gid|warn_dev)) exit(MKFS_EX_ERROR); - return EXIT_SUCCESS; + return MKFS_EX_OK; } diff --git a/misc-utils/findfs.c b/misc-utils/findfs.c index 7935232eb..7d2d803dd 100644 --- a/misc-utils/findfs.c +++ b/misc-utils/findfs.c @@ -63,11 +63,11 @@ int main(int argc, char **argv) switch (c) { case 'V': printf(UTIL_LINUX_VERSION); - return EXIT_SUCCESS; + return FINDFS_SUCCESS; case 'h': usage(FINDFS_SUCCESS); default: - errtryhelp(EXIT_FAILURE); + errtryhelp(FINDFS_USAGE_ERROR); } dev = blkid_evaluate_tag(argv[1], NULL, NULL); diff --git a/sys-utils/tunelp.c b/sys-utils/tunelp.c index 8cfbe80a2..89afff1ba 100644 --- a/sys-utils/tunelp.c +++ b/sys-utils/tunelp.c @@ -71,14 +71,17 @@ #include "lp.h" #include "nls.h" -#include "xalloc.h" #include "closestream.h" +#define EXIT_LP_MALLOC 2 #define STRTOXX_EXIT_CODE 3 #define EXIT_LP_IO_ERR 4 #include "strutils.h" +#define XALLOC_EXIT_CODE EXIT_LP_MALLOC +#include "xalloc.h" + struct command { long op; long val; |