Depending upon what the platform of your host computer is there
are some simple untility in unix called:
htonl, htons, ntohl, ntohs
check out the "man pages":
"htonl, htons, ntohl, ntohs - convert values between host
and network byte order
...
On the i80x86 the host byte order is Least Significant
Byte first, whereas the network byte order, as used on the
Internet, is Most Significant Byte first."
I hope this helps.
Tim Smith
_____________________________________________________________________
Timothy Paul Smith Research Scientist
MIT Bates Lab tim_smith@mit.edu
21 Manning Rd. tel: (617) 253-9207
Middleton, MA 01949 fax: (617) 253-9599
This archive was generated by hypermail 2b29 : Tue Jan 02 2001 - 11:50:34 MET