PDA

View Full Version : DNS lookup inside a C program .. how?



kernelhaxor
October 15th, 2008, 10:01 AM
I have a C program in which I need to be able to translate domain names into IP addresses.
I did google but couldn't find simple solutions. I know there are some simple functions which can do this.

Any help?

supirman
October 15th, 2008, 10:09 AM
http://www.beej.us/guide/bgnet/output/html/singlepage/bgnet.html#getaddrinfo

kernelhaxor
October 15th, 2008, 10:13 AM
http://www.beej.us/guide/bgnet/output/html/singlepage/bgnet.html#getaddrinfo

Thanks a lot! Will try that out ..