Strange Problem with sizeof operator betwen kernel and user mode

I have a strange problem with the use of ‘sizeof’. I have defined a
BOOT_SECTOR structure (512 bytes that represent the boot sector of my
virtual disk), and somewhere in my kernel driver code
<> give me the size of the boot sector structure which
is 512 bytes.
When I use the same code in user mode code I got 520 bytes for the size of
this same structure!!! This cause my user mode code to not function
properly. I have got the same problem
I doesn’t understand this difference with the sizeof operator betwen kernel
and user mode.
Does someone have some idea about this problem ?


Ibnou T.