From 281dcf7c1f004e04a0fd8e635454a4ec02fc26e5 Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Wed, 26 Jun 2019 19:33:37 +0200 Subject: [PATCH] Cast to proper types. --- client/TracyProfiler.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/client/TracyProfiler.cpp b/client/TracyProfiler.cpp index ec3c4b07..733f5352 100644 --- a/client/TracyProfiler.cpp +++ b/client/TracyProfiler.cpp @@ -437,7 +437,7 @@ static BroadcastMessage& GetBroadcastMessage( const char* procname, size_t pnsz, memcpy( msg.programName, procname, pnsz ); memset( msg.programName + pnsz, 0, WelcomeMessageProgramNameSize - pnsz ); - len = offsetof( BroadcastMessage, programName ) + pnsz + 1; + len = int( offsetof( BroadcastMessage, programName ) + pnsz + 1 ); return msg; } @@ -1157,7 +1157,7 @@ void Profiler::Worker() { lastBroadcast = t; const auto ts = std::chrono::duration_cast( std::chrono::system_clock::now().time_since_epoch() ).count(); - broadcastMsg.activeTime = ts - m_epoch; + broadcastMsg.activeTime = uint32_t( ts - m_epoch ); m_broadcast->Send( 8086, &broadcastMsg, broadcastLen ); } }