On Thu, Dec 1, 2011 at 6:45 PM, Christiano F. Haesbaert <haesba...@openbsd.org> wrote: > Hi, I think we should warn() on any error, not just EPERM. > This is more consistent with the rest of the code. > > ok ?
I disagree with this. The existing message is much clearer to the non-root mortal user that gets it and, IMO, it's clearer for the message to be sent to stdout with the rest of the output from the scan. As for errors other than EPERM, well, exactly what other errors *can* that call return in ifconfig? What problem are you guys trying to solve? Philip Guenther $ ifconfig rsu0 scan rsu0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500 lladdr 00:0a:79:de:84:aa priority: 4 groups: wlan media: IEEE802.11 autoselect status: no network ieee80211: nwid "" no permission to scan $ obj/ifconfig rsu0 scan rsu0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500 lladdr 00:0a:79:de:84:aa priority: 4 groups: wlan media: IEEE802.11 autoselect (autoselect mode 11b) status: no network ieee80211: nwid "" ifconfig: SIOCS80211SCAN: Operation not permitted