On Wed, 19 Aug 1998, Stephen A. Witt wrote: [ snip network vs. host order discussion ]
[ I wrote ] : > I'm coming into this late, and perhaps under-armed ... but no, I don't : > understand. Network order == big-endian ... so on little-endian : > machines htons(), htonl() et. do actually perform a conversion. On a : > big-endian system, no conversion is necessary because network order == : > host order on these machines. [ Steve wrote ] : wrong. The htons(), htonl(), etc. routines should ALWAYS be used : regardless of whether they are needed (little endian) or not (big endian). : This is just good software engineering practice. Anyone making this kind : of mistake will not be looked upon favorably by the other members of their : software development team are will likely receive a sharp retort. Bummer; as I re-read my email I see that I didn't express myself well at all. I agree that systems exchanging information should always use the routines in question (even though I didn't explicitly state that) ... my point about "no conversion necessary" was in response to Steve Carpenter's assertion that the functions "did nothing" on big-endian machines. Even though the functions do nothing, they should still be used for portability. Sorry about that! -- Nathan Norman MidcoNet 410 South Phillips Avenue Sioux Falls, SD mailto:[EMAIL PROTECTED] http://www.midco.net finger [EMAIL PROTECTED] for PGP Key: (0xA33B86E9)