kget WARNS6 cleanup

Larry Lansing lansil at fuzzynerd.com
Thu Jan 13 05:46:33 PST 2005


Index: Makefile
===================================================================
RCS file: /home/dcvs/src/sbin/kget/Makefile,v
retrieving revision 1.2
diff -u -r1.2 Makefile
--- Makefile	17 Jun 2003 04:27:33 -0000	1.2
+++ Makefile	13 Jan 2005 01:32:30 -0000
@@ -2,6 +2,7 @@
 # $DragonFly: src/sbin/kget/Makefile,v 1.2 2003/06/17 04:27:33 dillon Exp $
 #
 PROG=	kget
+WARNS?=	6
 MAN=	kget.8
 
 .include <bsd.prog.mk>
Index: kget.c
===================================================================
RCS file: /home/dcvs/src/sbin/kget/kget.c,v
retrieving revision 1.4
diff -u -r1.4 kget.c
--- kget.c	4 Feb 2004 17:40:00 -0000	1.4
+++ kget.c	13 Jan 2005 13:42:22 -0000
@@ -42,7 +42,7 @@
 {
 	int len,i;
 	char *buf;
-	char *mib1="machdep.uc_devlist";
+	const char *mib1="machdep.uc_devlist";
 	char name[9];
 	FILE *fout;
 
@@ -100,7 +100,7 @@
 				fprintf(fout,"drq %s%d %d\n",name,id->id_unit,
 					id->id_drq);
 			}
-			if(id->id_maddr>0) {
+			if (id->id_maddr != NULL) {
 				fprintf(fout,"iomem %s%d %p\n",name,id->id_unit,
 					id->id_maddr);
 			}





More information about the Submit mailing list