home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #18 / NN_1992_18.iso / spool / comp / sys / mac / programm / 14112 < prev    next >
Encoding:
Internet Message Format  |  1992-08-17  |  860 b 

  1. Path: sparky!uunet!usc!cs.utexas.edu!uwm.edu!ogicse!emory!athena.cs.uga.edu!kinsey
  2. From: kinsey@athena.cs.uga.edu (Kevin Kinsey)
  3. Newsgroups: comp.sys.mac.programmer
  4. Subject: byte alignment problem
  5. Message-ID: <1992Aug17.233739.19308@athena.cs.uga.edu>
  6. Date: 17 Aug 92 23:37:39 GMT
  7. Article-I.D.: athena.1992Aug17.233739.19308
  8. Sender: kinsey@athena.cs.uga.edu (Kevin Kinsey)
  9. Organization: University of Georgia, Athens
  10. Lines: 15
  11.  
  12. a quick question:
  13.  
  14.     if given a struct { char a; long b;} x;, what is the best method
  15.     to create a buffer that contains 'a' followed by 'b' WITHOUT the
  16.     implicit padding within the struct. This data must be written out
  17.     such that it can be read by a machine that expects the long to
  18.     straddle an even address boundary.
  19.  
  20.     any pointers about how to do this?
  21.  
  22. kevin
  23. -----
  24. kinsey@athena.cs.uga.edu
  25. University of Georgia
  26. Athens, GA 30309
  27.