diff options
author | hjk <qtc-committer@nokia.com> | 2009-09-30 12:51:54 +0200 |
---|---|---|
committer | hjk <qtc-committer@nokia.com> | 2009-09-30 12:51:54 +0200 |
commit | 163150e3e5ecbdb9f013bd5792204ae1232eeb0f (patch) | |
tree | 9d8f9050aef42e5b77ba82a76c1e04d665ccaf61 /src/plugins/debugger/gdb/attachgdbadapter.cpp | |
parent | 93902e5d0a9fb0ec2ab7790a3aa272c5eaf87910 (diff) | |
download | qt-creator-163150e3e5ecbdb9f013bd5792204ae1232eeb0f.tar.gz |
debugger: some state change fixes when shutting down in 'attach' mode
Diffstat (limited to 'src/plugins/debugger/gdb/attachgdbadapter.cpp')
-rw-r--r-- | src/plugins/debugger/gdb/attachgdbadapter.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/plugins/debugger/gdb/attachgdbadapter.cpp b/src/plugins/debugger/gdb/attachgdbadapter.cpp index fe727ad4c0..6cf1299634 100644 --- a/src/plugins/debugger/gdb/attachgdbadapter.cpp +++ b/src/plugins/debugger/gdb/attachgdbadapter.cpp @@ -135,7 +135,7 @@ void AttachGdbAdapter::handleAttach(const GdbResponse &response) m_engine->updateAll(); } else if (response.resultClass == GdbResultError) { QString msg = __(response.data.findChild("msg").data()); - setState(InferiorPreparationFailed); + setState(InferiorStartFailed); emit inferiorStartFailed(msg); } } @@ -167,6 +167,11 @@ void AttachGdbAdapter::shutdown() { switch (state()) { + case InferiorStartFailed: + m_engine->postCommand(_("-gdb-exit")); + setState(DebuggerNotReady); + return; + case InferiorStopped: setState(InferiorShuttingDown); m_engine->postCommand(_("detach"), CB(handleDetach)); |