From 1adc86964f3c56b2806b3886e3bf501aae062c1c Mon Sep 17 00:00:00 2001
From: Joerg Bornemann <joerg.bornemann@nokia.com>
Date: Tue, 20 Jul 2010 18:51:21 +0200
Subject: [PATCH] CdbEnginePrivate::endDebugging don't show error message on
 success

---
 src/plugins/debugger/cdb/cdbengine.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/plugins/debugger/cdb/cdbengine.cpp b/src/plugins/debugger/cdb/cdbengine.cpp
index 98ede2d10eb..61985684352 100644
--- a/src/plugins/debugger/cdb/cdbengine.cpp
+++ b/src/plugins/debugger/cdb/cdbengine.cpp
@@ -646,10 +646,10 @@ void CdbEnginePrivate::endDebugging(bool detachOnly)
     if (endSession(&errorMessage)) {
         STATE_DEBUG(Q_FUNC_INFO, __LINE__, "notifyEngineShutdownOk");
         m_engine->notifyEngineShutdownOk();
-        errorMessage = QString::fromLatin1("There were errors trying to end debugging:\n%1").arg(errorMessage);
-        m_engine->showMessage(errorMessage, LogError);
     } else {
         STATE_DEBUG(Q_FUNC_INFO, __LINE__, "notifyEngineShutdownFailed");
+        errorMessage = QString::fromLatin1("There were errors trying to end debugging:\n%1").arg(errorMessage);
+        m_engine->showMessage(errorMessage, LogError);
         m_engine->notifyEngineShutdownFailed();
     }
 }
-- 
GitLab