In C/C++, you can use the regular gethostbyname() call to turn a dotted-IP address string ("127.0.0.1" in the case of localhost) into a structure suitable for standard socket calls.
Now how do you translate it back? I know I can do some bit-shifting to get exactly which bit sets I want and just print those out, but is there any "standard" function to do this for me? It's for output into log files, so that I "really" know who/what I'm connecting to, and thus a human-readable dotted-address is a lot better than the raw hex.
Thanks.