From c846f8ba104f18053ce666de7e2da0a82deb45cd Mon Sep 17 00:00:00 2001 From: Chelsea Cassanova Date: Tue, 28 Nov 2023 13:45:02 -0500 Subject: [PATCH] [lldb][progress] Always report progress upon Progress object destruction (#73605) This commit allows a final progress report upon the destruction of the `Progress` object to happen at all times as opposed to when the progress was not completed. --- lldb/source/Core/Progress.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lldb/source/Core/Progress.cpp b/lldb/source/Core/Progress.cpp index 08be73f1470f..ea3f874916a9 100644 --- a/lldb/source/Core/Progress.cpp +++ b/lldb/source/Core/Progress.cpp @@ -30,10 +30,9 @@ Progress::~Progress() { // Make sure to always report progress completed when this object is // destructed so it indicates the progress dialog/activity should go away. std::lock_guard guard(m_mutex); - if (!m_completed) { + if (!m_completed) m_completed = m_total; - ReportProgress(); - } + ReportProgress(); } void Progress::Increment(uint64_t amount, std::string update) {