Fix socklen_t for libc5
[oweals/busybox.git] / tee.c
diff --git a/tee.c b/tee.c
index dc9876020b8299c7efb44e7ad967f1d294ba792d..439cf7dc5ea7569b9cef02a3379ec903c63f1499 100644 (file)
--- a/tee.c
+++ b/tee.c
@@ -2,7 +2,7 @@
 /*
  * Mini tee implementation for busybox
  *
- * Copyright (C) 1999,2000 by Lineo, inc.
+ * Copyright (C) 1999,2000,2001 by Lineo, inc.
  * Written by Matt Kraai <kraai@alumni.carnegiemellon.edu>
  *
  * This program is free software; you can redistribute it and/or modify
@@ -21,7 +21,7 @@
  *
  */
 
-#include "internal.h"
+#include "busybox.h"
 #include <getopt.h>
 #include <stdio.h>
 
@@ -38,7 +38,7 @@ tee_main(int argc, char **argv)
                        mode = "a";
                        break;
                default:
-                       usage(tee_usage);
+                       show_usage();
                }
        }
 
@@ -47,7 +47,7 @@ tee_main(int argc, char **argv)
        while (optind < argc) {
                if ((files[nfiles++] = fopen(argv[optind++], mode)) == NULL) {
                        nfiles--;
-                       errorMsg("%s: %s\n", argv[optind-1], strerror(errno));
+                       perror_msg("%s", argv[optind-1]);
                        status = 1;
                }
        }