From c979cdc1e32dd94a8da76168ad82acfc61be9273 Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Wed, 21 Jan 2004 23:37:54 +0000 Subject: (usage): Use EXIT_SUCCESS, not 0, for clarity. (usage): Don't bother normalizing exit status since the arg is already the correct exit status now. --- src/od.c | 6 +++--- src/paste.c | 7 ++++--- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/src/od.c b/src/od.c index 5dd9d9f4d..00b8f9939 100644 --- a/src/od.c +++ b/src/od.c @@ -1,5 +1,5 @@ /* od -- dump files in octal and other formats - Copyright (C) 92, 1995-2003 Free Software Foundation, Inc. + Copyright (C) 92, 1995-2004 Free Software Foundation, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -278,7 +278,7 @@ static struct option const long_options[] = void usage (int status) { - if (status != 0) + if (status != EXIT_SUCCESS) fprintf (stderr, _("Try `%s --help' for more information.\n"), program_name); else @@ -368,7 +368,7 @@ implies 32. By default, od uses -A o -t d2 -w 16.\n\ "), stdout); printf (_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT); } - exit (status == 0 ? EXIT_SUCCESS : EXIT_FAILURE); + exit (status); } /* Compute the greatest common denominator of U and V diff --git a/src/paste.c b/src/paste.c index caf23d6ef..ccd0e8baf 100644 --- a/src/paste.c +++ b/src/paste.c @@ -1,5 +1,6 @@ /* paste - merge lines of files - Copyright (C) 1984, 1997-2003 by David M. Ihnat + Copyright (C) 1997-2004 Free Software Foundation, Inc. + Copyright (C) 1984 David M. Ihnat This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -387,7 +388,7 @@ paste_serial (size_t nfiles, char **fnamptr) void usage (int status) { - if (status != 0) + if (status != EXIT_SUCCESS) fprintf (stderr, _("Try `%s --help' for more information.\n"), program_name); else @@ -414,7 +415,7 @@ Mandatory arguments to long options are mandatory for short options too.\n\ /* FIXME: add a couple of examples. */ printf (_("\nReport bugs to <%s>.\n"), PACKAGE_BUGREPORT); } - exit (status == 0 ? EXIT_SUCCESS : EXIT_FAILURE); + exit (status); } int -- cgit v1.2.3-70-g09d2