This is 2007. Byte order in network packets was an old solved problem in 1987. Why in the name of all that's holy isn't everything routinely sent in network byte order (using the standard hton*/ntoh* macros)?