Add in ifconfig and route
[oweals/busybox.git] / tty.c
diff --git a/tty.c b/tty.c
index 6f98d1b797404ce25829c19d7567a42471d85509..2a64b149d48555480b9bedaf7937788a4f36be50 100644 (file)
--- a/tty.c
+++ b/tty.c
  *
  */
 
-#include "internal.h"
+#include "busybox.h"
 #include <stdio.h>
+#include <stdlib.h>
+#include <unistd.h>
 #include <sys/types.h>
 
-static const char tty_usage[] = "tty\n\n"
-       "Print the file name of the terminal connected to standard input.\n\n"
-       "Options:\n"
-       "\t-s\tprint nothing, only return an exit status\n";
-
 extern int tty_main(int argc, char **argv)
 {
        char *tty;
@@ -43,5 +40,5 @@ extern int tty_main(int argc, char **argv)
                else
                        puts("not a tty");
        }
-       exit(isatty(0) ? TRUE : FALSE);
+       return(isatty(0) ? EXIT_SUCCESS : EXIT_FAILURE);
 }