Cleaned up error handling and uses of TRUE/FALSE.
authorMatt Kraai <kraai@debian.org>
Wed, 25 Oct 2000 16:38:00 +0000 (16:38 -0000)
committerMatt Kraai <kraai@debian.org>
Wed, 25 Oct 2000 16:38:00 +0000 (16:38 -0000)
coreutils/logname.c
logname.c

index 09ee24928a1ba6aa8dbf0242723ea9ed0bb210f8..89c409f006a5fb6809814de63675186e2b651219 100644 (file)
@@ -33,8 +33,7 @@ extern int logname_main(int argc, char **argv)
        my_getpwuid(user, geteuid());
        if (user) {
                puts(user);
-               exit(TRUE);
+               return EXIT_SUCCESS;
        }
-       errorMsg("no login name\n");
-       return(FALSE);
+       fatalError("no login name\n");
 }
index 09ee24928a1ba6aa8dbf0242723ea9ed0bb210f8..89c409f006a5fb6809814de63675186e2b651219 100644 (file)
--- a/logname.c
+++ b/logname.c
@@ -33,8 +33,7 @@ extern int logname_main(int argc, char **argv)
        my_getpwuid(user, geteuid());
        if (user) {
                puts(user);
-               exit(TRUE);
+               return EXIT_SUCCESS;
        }
-       errorMsg("no login name\n");
-       return(FALSE);
+       fatalError("no login name\n");
 }