DragonFly BSD
DragonFly submit List (threaded) for 2005-04
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

[PATCH] games/pig cleanup


From: Peter Avalos <pavalos@xxxxxxxxxxxx>
Date: Sun, 24 Apr 2005 21:31:28 -0700

ANSI function declarations.

WARNS6 cleanup.


Index: Makefile
===================================================================
RCS file: /ftp/pub/DragonFly/dcvs/src/games/pig/Makefile,v
retrieving revision 1.2
diff -u -r1.2 Makefile
--- Makefile	17 Jun 2003 04:25:24 -0000	1.2
+++ Makefile	25 Apr 2005 04:22:51 -0000
@@ -4,5 +4,6 @@
 
 PROG=	pig
 MAN=	pig.6
+WARNS?=	6
 
 .include <bsd.prog.mk>
Index: pig.c
===================================================================
RCS file: /ftp/pub/DragonFly/dcvs/src/games/pig/pig.c,v
retrieving revision 1.3
diff -u -r1.3 pig.c
--- pig.c	12 Nov 2003 14:53:53 -0000	1.3
+++ pig.c	25 Apr 2005 04:28:17 -0000
@@ -48,11 +48,9 @@
 void usage (void);
 
 int
-main(argc, argv)
-	int argc;
-	char *argv[];
+main(int argc, char **argv)
 {
-	int len;
+	unsigned int len;
 	int ch;
 	char buf[1024];
 
@@ -84,9 +82,7 @@
 }
 
 void
-pigout(buf, len)
-	char *buf;
-	int len;
+pigout(char *buf, int len)
 {
 	int ch, start;
 	int olen;
@@ -115,7 +111,7 @@
 }
 
 void
-usage()
+usage(void)
 {
 	(void)fprintf(stderr, "usage: pig\n");
 	exit(1);

Attachment: pgp00008.pgp
Description: PGP signature



[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]