![]() |
|
#1
|
|||
|
|||
|
sizeof() returns "wrong" Size of structure
Why is this structure 20 Bytes in size?
Code:
typedef struct STGAHeader{
BYTE m_uIDSize;
BYTE m_uColorMapType;
BYTE m_uImageType;
short m_sColorMapStart;
short m_sColorMapLength;
BYTE m_uColorMapBits;
short m_sXStart;
short m_sYStart;
short m_sWidth;
short m_sHeight;
BYTE m_uBits;
BYTE m_uDescriptor;
} STGAHeader;
For me 1+1+1+2+2+1+2+2+2+2+1+1 is 18 and not 20 but the compiler thinks different ![]() Its absolutely impossible that 6*integer1+6*integer2 is equal 20 (Intel 8.0 win) thx, Cobi Last edited by Cobi; 08-19-2005 at 06:39. |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How come new registrants given "guest" rank and not even a "friend" rank? | OldieHans | General Discussion | 4 | 09-25-2023 12:19 |
| When use "vendor defined encryption routines", how to set daemon related part? | bridgeic | General Discussion | 6 | 01-22-2015 11:35 |
| Wlscgen: Are "Vendor Id" and "Developer Id" different ? | Numega Softice | General Discussion | 6 | 02-12-2007 18:12 |