PERFORCE change 124852 for review

Constantine A. Murenin cnst at FreeBSD.org
Tue Aug 7 16:10:31 PDT 2007


http://perforce.freebsd.org/chv.cgi?CH=124852

Change 124852 by cnst at dale on 2007/08/07 23:09:30

	KNF

Affected files ...

.. //depot/projects/soc2007/cnst-sensors/sbin.sysctl/sysctl.c#3 edit

Differences ...

==== //depot/projects/soc2007/cnst-sensors/sbin.sysctl/sysctl.c#3 (text+ko) ====

@@ -143,7 +143,7 @@
 	if (Nflag && nflag)
 		usage();
 	if (aflag && argc == 0)
-		exit(sysctl_all(0, 0));
+		exit(sysctl_all(NULL, 0));
 	if (argc == 0)
 		usage();
 	while (argc-- > 0)
@@ -719,8 +719,8 @@
 	name1[0] = 0;
 	name1[1] = 2;
 	l1 = 2;
-	if (len) {
-		memcpy(name1+2, oid, len * sizeof(int));
+	if (len > 0) {
+		memcpy(name1 + 2, oid, len * sizeof(int));
 		l1 += len;
 	} else {
 		name1[2] = 1;


More information about the p4-projects mailing list