From: okellogg@cube.net (Oliver Kellogg)
Subject: Re: Byte sex confusion
Date: 1997/05/11
Date: 1997-05-11T00:00:00+00:00 [thread overview]
Message-ID: <5l3nko$mfb$1@salyko.cube.net> (raw)
In-Reply-To: 33733B21.59E2B600@spam.innocon.com
Steven O'Neill wrote:
> A simple solution is to convert everything into a standard
> representation, and have portable conversion routines to and from that
> representation.
> [... proposed solution elided ...]
Or, if you are lucky enough to have both sides of the program under
your control, interface to the network-to-host/host-to-network
functions in the Berkeley-Unix socket library:
htons() -- network to host short
ntohs() -- host to network short
htonl() -- network to host long
ntohl() -- host to network long
I believe these functions are also included in the forthcoming POSIX
P1003.5c Ada binding standard.
--Oliver
next prev parent reply other threads:[~1997-05-11 0:00 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
1997-05-07 0:00 Byte sex confusion Steven O'Neill
1997-05-08 0:00 ` Nick Roberts
1997-05-09 0:00 ` Robert Dewar
1997-05-14 0:00 ` Steve Sciance
1997-05-09 0:00 ` Roy Grimm
1997-05-09 0:00 ` Jeff Carter
1997-05-10 0:00 ` Robert Dewar
1997-05-11 0:00 ` Oliver Kellogg [this message]
1997-05-11 0:00 ` Matthew Heaney
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox