DragonFly submit List (threaded) for 2004-01
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]
Re: hostname(1) change
:Thanks, actually, that was my original intention, hence using -r (for reverse)
:and leaving -i for interface. I just knew whacking out the code for reverse
:would be quicker (that, and I had a need for it). I'll add some interface
:probing code and resubmit. I assume using sysctl(3) is the correct method
:for grabbing the interface details (I'm using ifconfig(8) as a reference) and
:using the first IP address found on the given interface would be appropriate?
:
:
:Cheers,
:
:--
:Kent Ibbetson
:bsd@xxxxxxxxxx
Take a look at the code to ifconfig in /usr/src/sbin/ifconfig/, which
appears to use sysctl to retrieve the interface list and a socket/ioctl
combo to retrieve the interface's info.
-Matt
Matthew Dillon
<dillon@xxxxxxxxxxxxx>
[
Date Prev][
Date Next]
[
Thread Prev][
Thread Next]
[
Date Index][
Thread Index]