PDA

View Full Version : dotted decimal IP address into hexadecimal



tdaly@sddsystems.com
11-03-2003, 01:01 PM
<hr width=50 align=left>Code ('http://www.mcpressonline.com/mc/showcode@@.6ae84f30/0')

G.Gaunt
11-04-2003, 06:03 AM
Thanks, if inet_addr() returns an unsigned 4-byte integer, why does the API documentation say inet_addr() returns signed "-1" if the API is unsuccessful?

G.Gaunt
11-04-2003, 07:05 AM
Does an API exist that converts dotted decimal IP address into hexadecimal? For example:<pre>200.201.202.203 => x'C8C9CACB'</pre>

tdaly@sddsystems.com
11-04-2003, 07:05 AM
You're right, the prototype I gave is wrong. It should specify 10i 0 for the return value. Thanks for catching it. Tom Daly