[oclug] [OT] C: get local ip?

David F. Skoll dfs at roaringpenguin.com
Tue Mar 19 18:49:20 EST 2002


On 19 Mar 2002, James Leigh wrote:

> what about if I know the default route is eth0, could I do i then?

Yes, you'd open a socket and get the IP address with an ioctl.  Get the
source code to named and take a look at how they do it.

--
David.




More information about the OCLUG mailing list