From b0a58d4664ead3bb3e61488e8d8b3bffae74d886 Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Tue, 14 Apr 2020 01:59:17 +0200 Subject: [PATCH] Don't shift left negative values. --- server/TracyEvent.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/TracyEvent.hpp b/server/TracyEvent.hpp index d970b981..0d71c0d1 100644 --- a/server/TracyEvent.hpp +++ b/server/TracyEvent.hpp @@ -301,7 +301,7 @@ struct MemEvent tracy_force_inline void SetThreadFree( uint16_t thread ) { memcpy( &_time_thread_free, &thread, 2 ); } tracy_force_inline void SetTimeThreadAlloc( int64_t time, uint16_t thread ) { time <<= 16; time |= thread; memcpy( &_time_thread_alloc, &time, 8 ); } - tracy_force_inline void SetTimeThreadFree( int64_t time, uint16_t thread ) { time <<= 16; time |= thread; memcpy( &_time_thread_free, &time, 8 ); } + tracy_force_inline void SetTimeThreadFree( int64_t time, uint16_t thread ) { uint64_t t; memcpy( &t, &time, 8 ); t <<= 16; t |= thread; memcpy( &_time_thread_free, &t, 8 ); } uint64_t _ptr_csalloc1; uint64_t _size_csalloc2;