On Tue, May 23, 2006 at 10:07:57PM +0200, Michael Kerrisk wrote: > > \fBoffsetof\fP() is a macro provided to compute the offset of a given > > element within a structure. The ordering within memory of a C > > structure is undefined, as is its size; compilers are allowed to > > reorder and pad structures. > ^^^^^^^ > Is that really true? I can't recall a case where I have ever seen > that, nor do I recall some such statement in the standards. > Please tell me more. I couldn't find anything to back this up, so you might be right..
One reason such things aren't as noticable is because most network protocols put the members in decreasing order of size, in an attempt to satisty the requirements for alignment and such, and inhibit any such compiler-specific :) things. Justin -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

