summaryrefslogtreecommitdiff
path: root/usr.bin/uuencode/uuencode.c
diff options
context:
space:
mode:
authorjtc <jtc@NetBSD.org>1993-08-27 22:30:10 +0000
committerjtc <jtc@NetBSD.org>1993-08-27 22:30:10 +0000
commitf7c6bf575a9439a48efddb59c128ba0588b2bdd2 (patch)
tree9fa4a79baa54c750aa01c4f7a3a8dbd3a9a68635 /usr.bin/uuencode/uuencode.c
parent5e2ed6648a9067a54a68f6a50df75a108fe15d8c (diff)
Minor tweaks: including header files to bring prototypes into scope,
explicitly declaring function return values, etc. to make gcc -Wall shut up.
Diffstat (limited to 'usr.bin/uuencode/uuencode.c')
-rw-r--r--usr.bin/uuencode/uuencode.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/usr.bin/uuencode/uuencode.c b/usr.bin/uuencode/uuencode.c
index 2c76d318438..e0a3eedf083 100644
--- a/usr.bin/uuencode/uuencode.c
+++ b/usr.bin/uuencode/uuencode.c
@@ -33,7 +33,7 @@
#ifndef lint
/*static char sccsid[] = "from: @(#)uuencode.c 5.9 (Berkeley) 6/1/90";*/
-static char rcsid[] = "$Id: uuencode.c,v 1.2 1993/08/01 18:03:38 mycroft Exp $";
+static char rcsid[] = "$Id: uuencode.c,v 1.3 1993/08/27 22:30:57 jtc Exp $";
#endif /* not lint */
/*
@@ -44,16 +44,20 @@ static char rcsid[] = "$Id: uuencode.c,v 1.2 1993/08/01 18:03:38 mycroft Exp $";
#include <sys/types.h>
#include <sys/stat.h>
#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <errno.h>
+static void encode();
+static void usage();
+
+int
main(argc, argv)
int argc;
char **argv;
{
- extern int optind;
- extern int errno;
struct stat sb;
int mode;
- char *strerror();
while (getopt(argc, argv, "") != EOF)
usage();
@@ -96,6 +100,7 @@ main(argc, argv)
/*
* copy from in to out, encoding as you go along.
*/
+static void
encode()
{
register int ch, n;
@@ -136,6 +141,7 @@ encode()
(void)putchar('\n');
}
+static void
usage()
{
(void)fprintf(stderr,"usage: uuencode [infile] remotefile\n");