Binary data file compatibility across machines

Bob Martin rmartin at clear.com
Mon Nov 26 19:50:22 AEST 1990


In article <STIBER.90Nov23134600 at maui.cs.ucla.edu> stiber at cs.ucla.edu (Michael D Stiber) writes:
>
>On different machines, the implementation of C data types is different.
>So, is there an already-existing, standard solution to this
>problem of binary data file transfer?
>--

CCITT has created a standard called X.409.  It nicely encodes data
in nearly any structure at all into a moderately concise binary 
format.  It provides for arrays, structures, strings, integers, and
user formats.  

I have used this standard quite successfully to store data in
files, or transmit data in "mail" messages between machines of
different architechtures.

I believe that the OSI standard for ASN.1 (X.208, X.209???) is
quite similar to X.409.  This standard is part of the presentation
layer in the OSI 7 layer model....

Another option is a unix convention called XDR.  I know very
little about it, other than it is used by RPC.  You might check
your unix manuals...


-- 
+-Robert C. Martin-----+:RRR:::CCC:M:::::M:| Nobody is responsible for |
| rmartin at clear.com    |:R::R:C::::M:M:M:M:| my words but me.  I want  |
| uunet!clrcom!rmartin |:RRR::C::::M::M::M:| all the credit, and all   |
+----------------------+:R::R::CCC:M:::::M:| the blame.  So there.     |



More information about the Comp.lang.c mailing list