Date: Fri, 31 Aug 2001 16:04:14 -0400 From: David Hill <david@phobia.ms> To: audit@freebsd.org Subject: users.c PATCH - please review Message-ID: <20010831160414.7125e88e.david@phobia.ms>
next in thread | raw e-mail | index | archive | help
This is a multi-part message in MIME format. --Multipart_Fri__31_Aug_2001_16:04:14_-0400_08178600 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Hello - I have patched users/users.c so that it will compile under WARNS?=2. I have both attached and cut/pasted it to the message. Please review it. Thanks - David Hill diff -ru /usr/src/usr.bin/users.orig/Makefile /usr/src/usr.bin/users/Makefile --- /usr/src/usr.bin/users.orig/Makefile Fri May 27 08:33:16 1994 +++ /usr/src/usr.bin/users/Makefile Fri Aug 31 15:57:39 2001 @@ -1,5 +1,6 @@ # @(#)Makefile 8.1 (Berkeley) 6/6/93 PROG= users +WARNS?= 2 .include <bsd.prog.mk> diff -ru /usr/src/usr.bin/users.orig/users.c /usr/src/usr.bin/users/users.c --- /usr/src/usr.bin/users.orig/users.c Fri Aug 27 21:07:14 1999 +++ /usr/src/usr.bin/users/users.c Fri Aug 31 15:58:20 2001 @@ -117,5 +117,8 @@ scmp(p, q) const void *p, *q; { - return(strncmp((char *)p, (char *)q, UT_NAMESIZE)); + const char *const pp1 = p; + const char *const pp2 = q; + + return(strncmp(pp1, pp2, UT_NAMESIZE)); } --Multipart_Fri__31_Aug_2001_16:04:14_-0400_08178600 Content-Type: application/octet-stream; name="users.c.patch" Content-Disposition: attachment; filename="users.c.patch" Content-Transfer-Encoding: base64 ZGlmZiAtcnUgL3Vzci9zcmMvdXNyLmJpbi91c2Vycy5vcmlnL01ha2VmaWxlIC91c3Ivc3JjL3Vz ci5iaW4vdXNlcnMvTWFrZWZpbGUKLS0tIC91c3Ivc3JjL3Vzci5iaW4vdXNlcnMub3JpZy9NYWtl ZmlsZQlGcmkgTWF5IDI3IDA4OjMzOjE2IDE5OTQKKysrIC91c3Ivc3JjL3Vzci5iaW4vdXNlcnMv TWFrZWZpbGUJRnJpIEF1ZyAzMSAxNTo1NzozOSAyMDAxCkBAIC0xLDUgKzEsNiBAQAogIwlAKCMp TWFrZWZpbGUJOC4xIChCZXJrZWxleSkgNi82LzkzCiAKIFBST0c9CXVzZXJzCitXQVJOUz89IDIK IAogLmluY2x1ZGUgPGJzZC5wcm9nLm1rPgpkaWZmIC1ydSAvdXNyL3NyYy91c3IuYmluL3VzZXJz Lm9yaWcvdXNlcnMuYyAvdXNyL3NyYy91c3IuYmluL3VzZXJzL3VzZXJzLmMKLS0tIC91c3Ivc3Jj L3Vzci5iaW4vdXNlcnMub3JpZy91c2Vycy5jCUZyaSBBdWcgMjcgMjE6MDc6MTQgMTk5OQorKysg L3Vzci9zcmMvdXNyLmJpbi91c2Vycy91c2Vycy5jCUZyaSBBdWcgMzEgMTU6NTg6MjAgMjAwMQpA QCAtMTE3LDUgKzExNyw4IEBACiBzY21wKHAsIHEpCiAJY29uc3Qgdm9pZCAqcCwgKnE7CiB7Ci0J cmV0dXJuKHN0cm5jbXAoKGNoYXIgKilwLCAoY2hhciAqKXEsIFVUX05BTUVTSVpFKSk7CisJY29u c3QgY2hhciAqY29uc3QgcHAxID0gcDsKKwljb25zdCBjaGFyICpjb25zdCBwcDIgPSBxOworCQor CXJldHVybihzdHJuY21wKHBwMSwgcHAyLCBVVF9OQU1FU0laRSkpOwogfQo= --Multipart_Fri__31_Aug_2001_16:04:14_-0400_08178600-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-audit" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010831160414.7125e88e.david>