debugger: fix problem where a manual 'continue' was needed after start up.

The problem was that the 'emptyness' of m_cookieForToken was used as an
indication that there was no response packet still in the air. However,
this hash was not reset after a debugging session was aborted using S-F5,
so it could contain items from a previous run, effectively preventing
automatic triggering of the necessary 'continue'.
This commit is contained in:
hjk
2009-06-29 13:28:01 +02:00
parent cc3a57a93a
commit ae3ac786e0

View File

@@ -198,6 +198,7 @@ void GdbEngine::initializeVariables()
m_autoContinue = false;
m_waitingForFirstBreakpointToBeHit = false;
m_commandsToRunOnTemporaryBreak.clear();
m_cookieForToken.clear();
}
void GdbEngine::gdbProcError(QProcess::ProcessError error)
@@ -1361,6 +1362,10 @@ int GdbEngine::currentFrame() const
bool GdbEngine::startDebugger(const QSharedPointer<DebuggerStartParameters> &sp)
{
// This should be set by the constructor or in exitDebugger().
QTC_ASSERT(m_debuggingHelperState == DebuggingHelperUninitialized,
initializeVariables());
debugMessage(DebuggerSettings::instance()->dump());
QStringList gdbArgs;