[SDL] local IP address (SDL_net)

Alvin alvinbeach at gmail.com
Wed May 23 09:12:41 PDT 2007


Hello all,

Does SDL_net provide a way of getting the local host's IP addresss? Not the 
loop-back address, but its routable address?

I've searched through SDL_net's docs and demos, but I can't seem to find this. 
I tried the "dnr" demo for SDL_net, but it says that it cannot resolve the 
hostname?

I'm using openSUSE 10.2 and the SDL libs:
SDL-1.2.11-22
SDL_net-1.2.6-2.1

I can do it using the Linux system calls, but I prefer to use SDL_net so the 
solution will be automagically portable.

Thanks,

Alvin


More information about the SDL mailing list