diff --git a/server/TracyWorker.cpp b/server/TracyWorker.cpp index 9548634c..e2d39947 100644 --- a/server/TracyWorker.cpp +++ b/server/TracyWorker.cpp @@ -3656,10 +3656,12 @@ int Worker::AddGhostZone( const VarArray& cs, Vectorempty() && vec->back().end.Val() > (int64_t)t ) { + const auto refBackTime = vec->back().end.Val(); auto tmp = vec; for(;;) { auto& back = tmp->back(); + if( back.end.Val() != refBackTime ) break; back.end.SetVal( t ); if( back.child < 0 ) break; tmp = &m_data.ghostChildren[back.child];