On 30 November 2011 12:39, Thomas de Grivel <[email protected]> wrote: > Hi, > > Index: ifconfig.c > =================================================================== > RCS file: /cvs/src/sbin/ifconfig/ifconfig.c,v > retrieving revision 1.252 > diff -u -p -r1.252 ifconfig.c > --- ifconfig.c 26 Nov 2011 23:38:18 -0000 1.252 > +++ ifconfig.c 30 Nov 2011 14:35:52 -0000 > @@ -2169,7 +2169,7 @@ ieee80211_listnodes(void) > > if (ioctl(s, SIOCS80211SCAN, (caddr_t)&ifr) != 0) { > if (errno == EPERM) > - printf("\t\tno permission to scan\n"); > + fprintf(stderr, "%s: no permission to scan\n", name); > goto done; > } > ? sbin_ifconfig.c-ieee80211-scan-stderr.diff > Index: ifconfig.c > =================================================================== > RCS file: /cvs/src/sbin/ifconfig/ifconfig.c,v > retrieving revision 1.252 > diff -u -p -r1.252 ifconfig.c > --- ifconfig.c 26 Nov 2011 23:38:18 -0000 1.252 > +++ ifconfig.c 30 Nov 2011 14:38:25 -0000 > @@ -2169,7 +2169,7 @@ ieee80211_listnodes(void) > > if (ioctl(s, SIOCS80211SCAN, (caddr_t)&ifr) != 0) { > if (errno == EPERM) > - printf("\t\tno permission to scan\n"); > + fprintf(stderr, "%s: no permission to scan\n", name); > goto done; > } > >
I think this should be warnx() and not fprintf(stderr, The rest of the code uses warnx().
