comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » data padding issue?
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
data padding issue? [message #10135] Thu, 16 October 1997 00:00
jyli is currently offline  jyli
Messages: 21
Registered: November 1995
Junior Member
In the Building IDL Application: P49 - 50

"All instances of structures contain an even number of bytes. On
machines whose native C compilers force short integers to begin
on an even byte boundary, IDL begins fields that are not of type
byte on an even byte boundary. Thus, a padding may appear (when
using ASSOC for I/O) after a byte field to cause the following
non-byte-type field to begin on an even byte."


Suppose my raw data record is 3 bytes long, no padding and pure
clean. I want to use structure {raw, t1:1b, t2:1} and read by
ASSOC. Because of the padding, the structure ocooupies 4 bytes.
Will that cause a problem, I mean reading a four bytes object
from 3 byte record ???

thanks,

------------------------------------------------------------ ------------
Jason Y. Li | Tel : (301) 286-1029
Code 913 | Fax : (301) 286-1759
NASA Goddard Space Flight Center | www : http://climate.gsfc.nasa.gov
Greenbelt, MD 20771, USA | email: jyli@climate.gsfc.nasa.gov
------------------------------------------------------------ ------------
Beauty of style, harmony, grace and good rhythm depend on simplicity.
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: move from SunOS to Solaris
Next Topic: widget_control,draw_widget

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 17:05:46 PDT 2025

Total time taken to generate the page: 0.00435 seconds