From 9cf46e6ae6465291feda8d812c190f3be5c5ee95 Mon Sep 17 00:00:00 2001 From: Bartosz Taudul Date: Wed, 13 Nov 2019 02:04:35 +0100 Subject: [PATCH] Fix lock time announce/terminate in older traces. --- server/TracyView.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/server/TracyView.cpp b/server/TracyView.cpp index 43695a3a..a2624a82 100644 --- a/server/TracyView.cpp +++ b/server/TracyView.cpp @@ -3864,11 +3864,11 @@ void View::DrawLockHeader( uint32_t id, const LockMap& lockmap, const SourceLoca int64_t timeTerminate = lockmap.timeTerminate; if( !lockmap.timeline.empty() ) { - if( timeAnnounce == 0 ) + if( timeAnnounce <= 0 ) { timeAnnounce = lockmap.timeline.front().ptr->Time(); } - if( timeTerminate == 0 ) + if( timeTerminate <= 0 ) { timeTerminate = lockmap.timeline.back().ptr->Time(); } @@ -11427,11 +11427,11 @@ void View::DrawLockInfoWindow() int64_t timeTerminate = lock.timeTerminate; if( !lock.timeline.empty() ) { - if( timeAnnounce == 0 ) + if( timeAnnounce <= 0 ) { timeAnnounce = lock.timeline.front().ptr->Time(); } - if( timeTerminate == 0 ) + if( timeTerminate <= 0 ) { timeTerminate = lock.timeline.back().ptr->Time(); }