[drupal-devel] OT: Binary data.
gordon at heydon.com.au
Wed Mar 16 07:33:58 UTC 2005
On Tue, 2005-03-15 at 23:57 -0600, Chris Johnson wrote:
> You do realize that the format of the integer "c" might well be different on
> the writing system and on the receiving system, don't you? Big endian versus
> little endian, or 2's-complement versus 1's-complment, for example.
> This is why RPC libraries always define external data formats (XDF), so that
> every process agrees on the same 4-byte representation of an integer.
> Having said that, take a look at the socket_send() page in the user comments.
> I think you will have to do your own conversion of the integer into 4 bytes
> and then send them.
Yes I do realise, and it is sad that I have come in on this project so
late. The first thing that I said was that the protocol was crap. And I
do realise that there is going to be possible endness issues.
Gordon Heydon <gordon at heydon.com.au>
More information about the drupal-devel