Jon Dowland wrote:
Because sizeof is not really the size of the struct, it is
the distance between adjacent structs in an array.
Alignment forces the extra bytes
I'm not quite sure I get what you're saying here. Yes,
alignment pads out the structure. But I'm not sure where
arrays come into it
> Because sizeof is not really the size of the struct, it is
> the distance between adjacent structs in an array.
> Alignment forces the extra bytes
I'm not quite sure I get what you're saying here. Yes,
alignment pads out the structure. But I'm not sure where
arrays come into it :- sizeof(struct
On Mon, 14 May 2007 16:24:59 +, J HU wrote:
> Dear all,
>
> Perhaps it's an easy/silly question but I don't understand how it works.
>
> (I'm working in a debian)
> I have declared a structure and I'm using the "sizeof" to get the size of
> this structure.
>
> After the call I get that the
On 5/14/07, J HU <[EMAIL PROTECTED]> wrote:
Dear all,
Perhaps it's an easy/silly question but I don't understand how it works.
(I'm working in a debian)
I have declared a structure and I'm using the "sizeof" to get the size of
this structure.
After the call I get that the total size is 64Bytes
J HU <[EMAIL PROTECTED]> wrote:
> I have declared a structure and I'm using the "sizeof" to get the size of
> this structure.
>
> After the call I get that the total size is 64Bytes but if I get the size
> of each field and I add them manually I get that it should be 61Bytes...
>
> Anyone knows
5 matches
Mail list logo