diff --git a/client/TracyProfiler.cpp b/client/TracyProfiler.cpp index 05ffc17e..2ca2c343 100755 --- a/client/TracyProfiler.cpp +++ b/client/TracyProfiler.cpp @@ -114,7 +114,7 @@ void Profiler::Worker() char* ptr = buf; for( int i=0; ihdr.type]; + ptr += QueueDataSize[ev->hdr.idx]; } } else { QueueItem hdr; if( !sock.Read( &hdr.hdr, sizeof( QueueHeader ), &tv, ShouldExit ) ) goto close; - if( !sock.Read( ((char*)&hdr) + sizeof( QueueHeader ), QueueDataSize[(uint8_t)hdr.hdr.type] - sizeof( QueueHeader ), &tv, ShouldExit ) ) goto close; + if( !sock.Read( ((char*)&hdr) + sizeof( QueueHeader ), QueueDataSize[hdr.hdr.idx] - sizeof( QueueHeader ), &tv, ShouldExit ) ) goto close; Process( hdr ); } }