diff --git a/d3xp/gamesys/Class.cpp b/d3xp/gamesys/Class.cpp index 9aeb06e..10dd4a0 100644 --- a/d3xp/gamesys/Class.cpp +++ b/d3xp/gamesys/Class.cpp @@ -284,7 +284,7 @@ idClass::FindUninitializedMemory */ void idClass::FindUninitializedMemory( void ) { #ifdef ID_DEBUG_UNINITIALIZED_MEMORY - unsigned long *ptr = ( ( unsigned long * )this ) - 1; + unsigned int *ptr = ( ( unsigned int * )this ) - 1; int size = *ptr; assert( ( size & 3 ) == 0 ); size >>= 2; @@ -453,7 +453,7 @@ void * idClass::operator new( size_t s ) { numobjects++; #ifdef ID_DEBUG_UNINITIALIZED_MEMORY - unsigned long *ptr = (unsigned long *)p; + unsigned int *ptr = (unsigned int *)p; int size = s; assert( ( size & 3 ) == 0 ); size >>= 3; @@ -475,7 +475,7 @@ void * idClass::operator new( size_t s, int, int, char *, int ) { numobjects++; #ifdef ID_DEBUG_UNINITIALIZED_MEMORY - unsigned long *ptr = (unsigned long *)p; + unsigned int *ptr = (unsigned int *)p; int size = s; assert( ( size & 3 ) == 0 ); size >>= 3; diff --git a/d3xp/gamesys/TypeInfo.cpp b/d3xp/gamesys/TypeInfo.cpp index 6ed9b64..2742c68 100644 --- a/d3xp/gamesys/TypeInfo.cpp +++ b/d3xp/gamesys/TypeInfo.cpp @@ -572,7 +572,7 @@ int idTypeInfoTools::WriteVariable_r( const void *varPtr, const char *varName, c // if this is a pointer isPointer = 0; for ( i = typeString.Length(); i > 0 && typeString[i - 1] == '*'; i -= 2 ) { - if ( varPtr == (void *)0xcdcdcdcd || ( varPtr != NULL && *((unsigned long *)varPtr) == 0xcdcdcdcd ) ) { + if ( varPtr == (void *)0xcdcdcdcd || ( varPtr != NULL && *((unsigned int *)varPtr) == 0xcdcdcdcd ) ) { common->Warning( "%s%s::%s%s references uninitialized memory", prefix, scope, varName, "" ); return typeSize; } @@ -1138,7 +1138,7 @@ int idTypeInfoTools::WriteVariable_r( const void *varPtr, const char *varName, c i = 0; do { - if ( *((unsigned long *)varPtr) == 0xcdcdcdcd ) { + if ( *((unsigned int *)varPtr) == 0xcdcdcdcd ) { common->Warning( "%s%s::%s%s uses uninitialized memory", prefix, scope, varName, "" ); break; } diff --git a/game/gamesys/Class.cpp b/game/gamesys/Class.cpp index c759739..750e441 100644 --- a/game/gamesys/Class.cpp +++ b/game/gamesys/Class.cpp @@ -284,7 +284,7 @@ idClass::FindUninitializedMemory */ void idClass::FindUninitializedMemory( void ) { #ifdef ID_DEBUG_UNINITIALIZED_MEMORY - unsigned long *ptr = ( ( unsigned long * )this ) - 1; + unsigned int *ptr = ( ( unsigned int * )this ) - 1; int size = *ptr; assert( ( size & 3 ) == 0 ); size >>= 2; @@ -453,7 +453,7 @@ void * idClass::operator new( size_t s ) { numobjects++; #ifdef ID_DEBUG_UNINITIALIZED_MEMORY - unsigned long *ptr = (unsigned long *)p; + unsigned int *ptr = (unsigned int *)p; int size = s; assert( ( size & 3 ) == 0 ); size >>= 3; @@ -475,7 +475,7 @@ void * idClass::operator new( size_t s, int, int, char *, int ) { numobjects++; #ifdef ID_DEBUG_UNINITIALIZED_MEMORY - unsigned long *ptr = (unsigned long *)p; + unsigned int *ptr = (unsigned int *)p; int size = s; assert( ( size & 3 ) == 0 ); size >>= 3; diff --git a/game/gamesys/TypeInfo.cpp b/game/gamesys/TypeInfo.cpp index 6ed9b64..2742c68 100644 --- a/game/gamesys/TypeInfo.cpp +++ b/game/gamesys/TypeInfo.cpp @@ -572,7 +572,7 @@ int idTypeInfoTools::WriteVariable_r( const void *varPtr, const char *varName, c // if this is a pointer isPointer = 0; for ( i = typeString.Length(); i > 0 && typeString[i - 1] == '*'; i -= 2 ) { - if ( varPtr == (void *)0xcdcdcdcd || ( varPtr != NULL && *((unsigned long *)varPtr) == 0xcdcdcdcd ) ) { + if ( varPtr == (void *)0xcdcdcdcd || ( varPtr != NULL && *((unsigned int *)varPtr) == 0xcdcdcdcd ) ) { common->Warning( "%s%s::%s%s references uninitialized memory", prefix, scope, varName, "" ); return typeSize; } @@ -1138,7 +1138,7 @@ int idTypeInfoTools::WriteVariable_r( const void *varPtr, const char *varName, c i = 0; do { - if ( *((unsigned long *)varPtr) == 0xcdcdcdcd ) { + if ( *((unsigned int *)varPtr) == 0xcdcdcdcd ) { common->Warning( "%s%s::%s%s uses uninitialized memory", prefix, scope, varName, "" ); break; }