On Thu, Sep 13, 2001 at 11:09:04PM +0200, Kjeld Borch Egevang wrote: > Perhaps I don't get you point, but I get the same with: > > int main() > { > rtx rt; > > put_code(&rt, (short)5); > printf("gen_rtx, code=%d\n", (int)rt.code); > } > That is not what I meant. You have typedef struct rtx_def { short code; int dummy; } rtx; The first field of rtx_def is short. for (; length >= 0; length--) ((int *) rt)[length] = 0; But you access it as int. If you do for (; length >= 0; length--) ((short *) rt)[length] = 0; It will be ok. H.J.