# HG changeset patch # User Sam Lantinga # Date 1326110796 18000 # Node ID bc960ba38aae2dd4892b929f63617345b55ec797 # Parent a1d200f7ed38f1fd2f526067f94a3597fa647cdc Fixed structure alignment mismatch between Visual Studio and gcc on 64-bit architectures. diff -r a1d200f7ed38 -r bc960ba38aae include/begin_code.h --- a/include/begin_code.h Mon Jan 09 04:36:57 2012 -0500 +++ b/include/begin_code.h Mon Jan 09 07:06:36 2012 -0500 @@ -132,7 +132,12 @@ #ifdef __BORLANDC__ #pragma nopackwarning #endif +#ifdef _M_X64 +/* Use 8-byte alignment on 64-bit architectures, so pointers are aligned */ +#pragma pack(push,8) +#else #pragma pack(push,4) +#endif #elif (defined(__MWERKS__) && defined(__MACOS__)) #pragma options align=mac68k4byte #pragma enumsalwaysint on