Subject: dev/ic/vga_raster.c:315: warning: unused variable `typestr'
To: None <current-users@netbsd.org>
From: None <hubert@feyrer.de>
List: current-users
Date: 11/27/2002 22:11:43
Am I the only one to see this on i386/current:
miyu# /usr/cvs/src-current/tools/obj.i386/tools.NetBSD-1.6I-i386/bin/nbmake-i386
/usr/cvs/src-current/tools/obj.i386/tools.NetBSD-1.6I-i386/bin/i386--netbsdelf-gcc
-ffreestanding -O2 -Werror -Wall -Wno-main -Wno-format-zero-length
-Wpointer-arith -Wmissing-prototypes -Wstrict-prototypes
-Wno-uninitialized -Di386 -I. -I../../../../arch -I../../../.. -nostdinc
-DLKM -DMAXUSERS=32 -D_KERNEL -D_KERNEL_OPT -c
/usr/cvs/src-current/sys/arch/i386/compile/MIYU/../../../../dev/ic/vga_raster.c
cc1: warnings being treated as errors
/usr/cvs/src-current/sys/arch/i386/compile/MIYU/../../../../dev/ic/vga_raster.c:
In function `vga_cnattach':
/usr/cvs/src-current/sys/arch/i386/compile/MIYU/../../../../dev/ic/vga_raster.c:315:
warning: unused variable `typestr'
*** Error code 1
The following patch fixes things for me:
Index: vga_raster.c
===================================================================
RCS file: /cvsroot/syssrc/sys/dev/ic/vga_raster.c,v
retrieving revision 1.4
diff -u -r1.4 vga_raster.c
--- vga_raster.c 2002/11/04 08:05:53 1.4
+++ vga_raster.c 2002/11/27 21:06:06
@@ -312,7 +312,9 @@
{
long defattr;
const struct wsscreen_descr *scr;
+#ifdef VGA_CONSOLE_SCREENTYPE
char *typestr;
+#endif
if (check && !vga_common_probe(iot, memt))
return (ENXIO);
- Hubert
--
Hubert Feyrer <hubert@feyrer.de>