Fix printf types.

This commit is contained in:
Bartosz Taudul 2018-08-22 16:31:09 +02:00
parent 6e3909825f
commit a1a9f6d610

View File

@ -297,7 +297,7 @@ static const char* GetHostInfo()
MEMORYSTATUSEX statex; MEMORYSTATUSEX statex;
statex.dwLength = sizeof( statex ); statex.dwLength = sizeof( statex );
GlobalMemoryStatusEx( &statex ); GlobalMemoryStatusEx( &statex );
ptr += sprintf( ptr, "RAM: %i MB\n", statex.ullTotalPhys / 1024 / 1024 ); ptr += sprintf( ptr, "RAM: %I64u MB\n", statex.ullTotalPhys / 1024 / 1024 );
#elif defined __linux__ #elif defined __linux__
struct sysinfo sysInfo; struct sysinfo sysInfo;
sysinfo( &sysInfo ); sysinfo( &sysInfo );
@ -324,13 +324,13 @@ LONG WINAPI CrashFilter( PEXCEPTION_POINTERS pExp )
switch( pExp->ExceptionRecord->ExceptionInformation[0] ) switch( pExp->ExceptionRecord->ExceptionInformation[0] )
{ {
case 0: case 0:
msgPtr += sprintf( msgPtr, "Read violation at address 0x%p.", pExp->ExceptionRecord->ExceptionInformation[1] ); msgPtr += sprintf( msgPtr, "Read violation at address 0x%Iu.", pExp->ExceptionRecord->ExceptionInformation[1] );
break; break;
case 1: case 1:
msgPtr += sprintf( msgPtr, "Write violation at address 0x%p.", pExp->ExceptionRecord->ExceptionInformation[1] ); msgPtr += sprintf( msgPtr, "Write violation at address 0x%Iu.", pExp->ExceptionRecord->ExceptionInformation[1] );
break; break;
case 8: case 8:
msgPtr += sprintf( msgPtr, "DEP violation at address 0x%p.", pExp->ExceptionRecord->ExceptionInformation[1] ); msgPtr += sprintf( msgPtr, "DEP violation at address 0x%Iu.", pExp->ExceptionRecord->ExceptionInformation[1] );
break; break;
default: default:
break; break;