From 9157f12ed2df85002af2941bfed09876dbe1f8a0 Mon Sep 17 00:00:00 2001 From: hjk Date: Tue, 29 Sep 2009 14:40:23 +0200 Subject: [PATCH] debugger: fix pid parsing from gdb output on Mac --- src/plugins/debugger/gdb/gdbengine.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/plugins/debugger/gdb/gdbengine.cpp b/src/plugins/debugger/gdb/gdbengine.cpp index 8ad7a964feb..7ceb24d688c 100644 --- a/src/plugins/debugger/gdb/gdbengine.cpp +++ b/src/plugins/debugger/gdb/gdbengine.cpp @@ -514,11 +514,15 @@ void GdbEngine::handleResponse(const QByteArray &buff) static QRegExp re1(_("New .hread 0x[0-9a-f]+ \\(LWP ([0-9]*)\\)")); // MinGW 6.8: [New thread 2437.0x435345] static QRegExp re2(_("New .hread ([0-9]+)\\.0x[0-9a-f]*")); + // Mac: [Switching to process 9294 local thread 0x2e03] + static QRegExp re3(_("Switching to process ([0-9]+) local thread")); QTC_ASSERT(re1.isValid() && re2.isValid(), return); if (re1.indexIn(_(data)) != -1) maybeHandleInferiorPidChanged(re1.cap(1)); else if (re2.indexIn(_(data)) != -1) maybeHandleInferiorPidChanged(re2.cap(1)); + else if (re3.indexIn(_(data)) != -1) + maybeHandleInferiorPidChanged(re3.cap(1)); } // Show some messages to give the impression something happens.