From 4c4e09cf11e3d2ada91469837352c6c2c5f43f36 Mon Sep 17 00:00:00 2001 From: Sobol Date: Thu, 10 Mar 2022 22:22:16 +0000 Subject: [PATCH] Fixed missing value in initialisation of SymbolQueueItem. On some compilers it is compilation error, it may be also potential crash ( uninitialised value ). --- client/TracyProfiler.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/client/TracyProfiler.cpp b/client/TracyProfiler.cpp index a9f674bd..bf34a59a 100644 --- a/client/TracyProfiler.cpp +++ b/client/TracyProfiler.cpp @@ -3117,7 +3117,7 @@ void Profiler::SendCallstackAlloc( uint64_t _ptr ) void Profiler::QueueCallstackFrame( uint64_t ptr ) { #ifdef TRACY_HAS_CALLSTACK - m_symbolQueue.emplace( SymbolQueueItem { SymbolQueueItemType::CallstackFrame, ptr } ); + m_symbolQueue.emplace( SymbolQueueItem { SymbolQueueItemType::CallstackFrame, ptr, 0 } ); #else AckServerQuery(); #endif @@ -3138,7 +3138,7 @@ void Profiler::QueueSymbolQuery( uint64_t symbol ) } else { - m_symbolQueue.emplace( SymbolQueueItem { SymbolQueueItemType::SymbolQuery, symbol } ); + m_symbolQueue.emplace( SymbolQueueItem { SymbolQueueItemType::SymbolQuery, symbol, 0 } ); } #else AckServerQuery(); @@ -3148,7 +3148,7 @@ void Profiler::QueueSymbolQuery( uint64_t symbol ) void Profiler::QueueCodeLocation( uint64_t ptr ) { #ifdef TRACY_HAS_CALLSTACK - m_symbolQueue.emplace( SymbolQueueItem { SymbolQueueItemType::CodeLocation, ptr } ); + m_symbolQueue.emplace( SymbolQueueItem { SymbolQueueItemType::CodeLocation, ptr, 0 } ); #else AckServerQuery(); #endif @@ -3157,7 +3157,7 @@ void Profiler::QueueCodeLocation( uint64_t ptr ) void Profiler::QueueExternalName( uint64_t ptr ) { #ifdef TRACY_HAS_SYSTEM_TRACING - m_symbolQueue.emplace( SymbolQueueItem { SymbolQueueItemType::ExternalName, ptr } ); + m_symbolQueue.emplace( SymbolQueueItem { SymbolQueueItemType::ExternalName, ptr, 0 } ); #endif }