Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 3 Dec 2004 23:24:35 GMT
From:      Sam Leffler <sam@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 66372 for review
Message-ID:  <200412032324.iB3NOZAF004683@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=66372

Change 66372 by sam@sam_ebb on 2004/12/03 23:23:41

	replace perror with warn and identify the parameters on failure

Affected files ...

.. //depot/projects/wifi/sbin/ifconfig/af_inet6.c#4 edit

Differences ...

==== //depot/projects/wifi/sbin/ifconfig/af_inet6.c#4 (text+ko) ====

@@ -203,12 +203,12 @@
 
 	strncpy(ifr6.ifr_name, ifr.ifr_name, sizeof(ifr.ifr_name));
 	if ((s6 = socket(AF_INET6, SOCK_DGRAM, 0)) < 0) {
-		perror("ifconfig: socket");
+		warn("socket(AF_INET6,SOCK_DGRAM)");
 		return;
 	}
 	ifr6.ifr_addr = *sin;
 	if (ioctl(s6, SIOCGIFAFLAG_IN6, &ifr6) < 0) {
-		perror("ifconfig: ioctl(SIOCGIFAFLAG_IN6)");
+		warn("ioctl(SIOCGIFAFLAG_IN6)");
 		close(s6);
 		return;
 	}
@@ -216,7 +216,7 @@
 	memset(&lifetime, 0, sizeof(lifetime));
 	ifr6.ifr_addr = *sin;
 	if (ioctl(s6, SIOCGIFALIFETIME_IN6, &ifr6) < 0) {
-		perror("ifconfig: ioctl(SIOCGIFALIFETIME_IN6)");
+		warn("ioctl(SIOCGIFALIFETIME_IN6)");
 		close(s6);
 		return;
 	}



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200412032324.iB3NOZAF004683>