1
0
mirror of https://github.com/wolfpld/tracy.git synced 2025-03-20 07:40:02 +08:00

Fixed compiler warnings.

This commit is contained in:
Till Rathmann
2019-02-20 16:28:27 +01:00
parent 77abc3bffd
commit 29140afe0c
3 changed files with 52 additions and 47 deletions
+8 -8
View File
@@ -88,9 +88,9 @@ namespace tracy
namespace
{
BOOL CALLBACK InitOnceCallback(
PINIT_ONCE initOnce,
PVOID Parameter,
PVOID *Context)
PINIT_ONCE /*initOnce*/,
PVOID /*Parameter*/,
PVOID* /*Context*/)
{
rpmalloc_initialize();
return TRUE;
@@ -396,13 +396,13 @@ LONG WINAPI CrashFilter( PEXCEPTION_POINTERS pExp )
switch( pExp->ExceptionRecord->ExceptionInformation[0] )
{
case 0:
msgPtr += sprintf( msgPtr, "Read violation at address 0x%" PRIxMAX ".", pExp->ExceptionRecord->ExceptionInformation[1] );
msgPtr += sprintf( msgPtr, "Read violation at address 0x%" PRIxPTR ".", pExp->ExceptionRecord->ExceptionInformation[1] );
break;
case 1:
msgPtr += sprintf( msgPtr, "Write violation at address 0x%" PRIxMAX ".", pExp->ExceptionRecord->ExceptionInformation[1] );
msgPtr += sprintf( msgPtr, "Write violation at address 0x%" PRIxPTR ".", pExp->ExceptionRecord->ExceptionInformation[1] );
break;
case 8:
msgPtr += sprintf( msgPtr, "DEP violation at address 0x%" PRIxMAX ".", pExp->ExceptionRecord->ExceptionInformation[1] );
msgPtr += sprintf( msgPtr, "DEP violation at address 0x%" PRIxPTR ".", pExp->ExceptionRecord->ExceptionInformation[1] );
break;
default:
break;
@@ -503,7 +503,7 @@ static long s_profilerTid = 0;
static char s_crashText[1024];
static std::atomic<bool> s_alreadyCrashed( false );
static void ThreadFreezer( int signal )
static void ThreadFreezer( int /*signal*/ )
{
for(;;) sleep( 1000 );
}
@@ -534,7 +534,7 @@ static inline void HexPrint( char*& ptr, uint64_t val )
while( bptr != buf );
}
static void CrashHandler( int signal, siginfo_t* info, void* ucontext )
static void CrashHandler( int signal, siginfo_t* info, void* /*ucontext*/ )
{
bool expected = false;
if( !s_alreadyCrashed.compare_exchange_strong( expected, true ) ) ThreadFreezer( signal );