Commit f6186e0c authored by David Schulz's avatar David Schulz
Browse files

Cdb: Clear output buffer after assigning it to the response.



Change-Id: I35d5b47d4b56863bd5d24c2ee9c5c6bf115fb6d0
Reviewed-by: default avatarChristian Stenger <christian.stenger@theqtcompany.com>
parent 5b28c52e
...@@ -2408,10 +2408,7 @@ void CdbEngine::parseOutputLine(QByteArray line) ...@@ -2408,10 +2408,7 @@ void CdbEngine::parseOutputLine(QByteArray line)
QTC_ASSERT(token == m_currentBuiltinResponseToken, return); QTC_ASSERT(token == m_currentBuiltinResponseToken, return);
if (boolSetting(VerboseLog)) if (boolSetting(VerboseLog))
showMessage(QLatin1String(m_currentBuiltinResponse), LogMisc); showMessage(QLatin1String(m_currentBuiltinResponse), LogMisc);
m_currentBuiltinResponseToken = -1; if (command.callback) {
m_currentBuiltinResponse.clear();
if (!command.callback)
return;
DebuggerResponse response; DebuggerResponse response;
response.token = token; response.token = token;
response.data.m_name = "data"; response.data.m_name = "data";
...@@ -2419,6 +2416,9 @@ void CdbEngine::parseOutputLine(QByteArray line) ...@@ -2419,6 +2416,9 @@ void CdbEngine::parseOutputLine(QByteArray line)
response.data.m_type = GdbMi::Tuple; response.data.m_type = GdbMi::Tuple;
response.resultClass = ResultDone; response.resultClass = ResultDone;
command.callback(response); command.callback(response);
}
m_currentBuiltinResponseToken = -1;
m_currentBuiltinResponse.clear();
} else { } else {
// Record output of current command // Record output of current command
if (!m_currentBuiltinResponse.isEmpty()) if (!m_currentBuiltinResponse.isEmpty())
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment