diff options
author | Jim Meyering <jim@meyering.net> | 2000-05-07 14:57:52 +0000 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 2000-05-07 14:57:52 +0000 |
commit | c6b0fefde1f58793f2ac9e164c94197fcac230cf (patch) | |
tree | c6fd0f4258a4621b47644ad9ff9b60c07edf8c69 /src | |
parent | 2d4fd1ab6e69af49756ced43d0fe1b8bb07ae174 (diff) | |
download | coreutils-c6b0fefde1f58793f2ac9e164c94197fcac230cf.tar.xz |
Include "closeout.h".
(main): Call atexit with close_stdout.
Diffstat (limited to 'src')
-rw-r--r-- | src/pwd.c | 4 | ||||
-rw-r--r-- | src/seq.c | 4 |
2 files changed, 4 insertions, 4 deletions
@@ -66,6 +66,8 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); + atexit (close_stdout); + parse_long_options (argc, argv, PROGRAM_NAME, GNU_PACKAGE, VERSION, AUTHORS, usage); @@ -77,7 +79,5 @@ main (int argc, char **argv) error (1, errno, _("cannot get current directory")); printf ("%s\n", wd); - close_stdout (); - exit (0); } @@ -339,6 +339,8 @@ main (int argc, char **argv) bindtextdomain (PACKAGE, LOCALEDIR); textdomain (PACKAGE); + atexit (close_stdout); + equal_width = 0; separator = "\n"; first = 1.0; @@ -455,7 +457,5 @@ format string may not be specified when printing equal width strings")); errs = print_numbers (format_str); - close_stdout (); - exit (errs); } |