Date: Tue, 14 Mar 2000 10:38:04 +0000 From: David Malone <dwmalone@maths.tcd.ie> To: freebsd-hackers@freebsd.org Subject: userconfig.c warnings. Message-ID: <200003141038.aa88860@salmon.maths.tcd.ie>
next in thread | raw e-mail | index | archive | help
I just noticed these warnings in userconfig.c - I presume they've been there for ages, however I think they should probably be fixed. What is happening is that some devices have descriptions that are too long to fit into the 60 alotted characters, and resultingly are not nul terminated. strcpy seems to be used on these strings later, which could result in trouble, except for the fact that the string is followed by some flags which will usually contain a nul byte. An I confused, or should I send-pr? David. cc -c -O -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing -prototypes -Wpointer-arith -Winline -Wcast-qual -fformat-extensions -ansi -no stdinc -I- -I. -I../.. -I../../../include -D_KERNEL -include opt_global.h -elf -mpreferred-stack-boundary=2 ../../i386/i386/userconfig.c ../../i386/i386/userconfig.c:387: warning: initializer-string for array of chars is too long ../../i386/i386/userconfig.c:387: warning: (near initialization for `device_info [48].name') ../../i386/i386/userconfig.c:396: warning: initializer-string for array of chars is too long ../../i386/i386/userconfig.c:396: warning: (near initialization for `device_info [57].name') To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200003141038.aa88860>