diff --git a/Core/Libraries/Source/WWVegas/WWLib/always.h b/Core/Libraries/Source/WWVegas/WWLib/always.h index d63eeec2fb..c58e6dd8e4 100644 --- a/Core/Libraries/Source/WWVegas/WWLib/always.h +++ b/Core/Libraries/Source/WWVegas/WWLib/always.h @@ -144,7 +144,7 @@ private: \ return The##ARGCLASS##Pool; \ } \ protected: \ - virtual int glueEnforcer() const { return sizeof(this); } \ + virtual void glueEnforcer() const { } \ public: \ inline void* operator new(size_t s) { return allocateFromW3DMemPool(getClassMemoryPool(), s); } \ inline void operator delete(void *p) { freeFromW3DMemPool(getClassMemoryPool(), p); } \ @@ -162,7 +162,7 @@ class W3DMPO } protected: // we never call this; it is present to cause compile errors in descendent classes - virtual int glueEnforcer() const = 0; + virtual void glueEnforcer() const = 0; public: virtual ~W3DMPO() { /* nothing */ } }; diff --git a/Generals/Code/GameEngine/Include/Common/BitFlagsIO.h b/Generals/Code/GameEngine/Include/Common/BitFlagsIO.h index 2d7be09044..197c79f31f 100644 --- a/Generals/Code/GameEngine/Include/Common/BitFlagsIO.h +++ b/Generals/Code/GameEngine/Include/Common/BitFlagsIO.h @@ -214,7 +214,11 @@ void BitFlags::xfer(Xfer* xfer) { // just call the xfer implementation on the data values +#if RETAIL_COMPATIBLE_CRC xfer->xferUser( this, sizeof( this ) ); +#else + xfer->xferUser( this, sizeof( *this ) ); +#endif } else diff --git a/GeneralsMD/Code/GameEngine/Include/Common/BitFlagsIO.h b/GeneralsMD/Code/GameEngine/Include/Common/BitFlagsIO.h index 2c9d8ba8aa..f579652028 100644 --- a/GeneralsMD/Code/GameEngine/Include/Common/BitFlagsIO.h +++ b/GeneralsMD/Code/GameEngine/Include/Common/BitFlagsIO.h @@ -214,7 +214,11 @@ void BitFlags::xfer(Xfer* xfer) { // just call the xfer implementation on the data values +#if RETAIL_COMPATIBLE_CRC xfer->xferUser( this, sizeof( this ) ); +#else + xfer->xferUser( this, sizeof( *this ) ); +#endif } else