diff options
author | Jim Meyering <jim@meyering.net> | 2003-07-19 08:16:38 +0000 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 2003-07-19 08:16:38 +0000 |
commit | fe52d65af0fcfdc89b67442d4516449eec41d546 (patch) | |
tree | ac6527c5034bf3119da426440a7d086fd32ef507 /src | |
parent | 3fd76bf433716652406a4e5669da1faf507214e1 (diff) | |
download | coreutils-fe52d65af0fcfdc89b67442d4516449eec41d546.tar.xz |
Include "exitfail.h".
(main): Set exit_failure rather than calling close_stdout_set_status.
Diffstat (limited to 'src')
-rw-r--r-- | src/date.c | 3 | ||||
-rw-r--r-- | src/sort.c | 2 | ||||
-rw-r--r-- | src/tty.c | 3 |
3 files changed, 5 insertions, 3 deletions
diff --git a/src/date.c b/src/date.c index 10e91914c..8f52f3708 100644 --- a/src/date.c +++ b/src/date.c @@ -29,6 +29,7 @@ #include "argmatch.h" #include "closeout.h" #include "error.h" +#include "exitfail.h" #include "getdate.h" #include "getline.h" #include "posixtm.h" @@ -309,7 +310,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - close_stdout_set_status (2); + exit_failure = 2; atexit (close_stdout); while ((optc = getopt_long (argc, argv, short_options, long_options, NULL)) diff --git a/src/sort.c b/src/sort.c index 2d90724ee..631675924 100644 --- a/src/sort.c +++ b/src/sort.c @@ -2183,8 +2183,8 @@ main (int argc, char **argv) atexit (cleanup); + exit_failure = SORT_FAILURE; atexit (close_stdout); - close_stdout_set_status (SORT_FAILURE); hard_LC_COLLATE = hard_locale (LC_COLLATE); #if HAVE_NL_LANGINFO @@ -29,6 +29,7 @@ #include "system.h" #include "closeout.h" +#include "exitfail.h" #include "error.h" /* The official name of this program (e.g., no `g' prefix). */ @@ -84,7 +85,7 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); - close_stdout_set_status (3); + exit_failure = 3; atexit (close_stdout); silent = 0; |