diff options
author | hjk <qtc-committer@nokia.com> | 2011-03-29 09:58:21 +0200 |
---|---|---|
committer | hjk <qtc-committer@nokia.com> | 2011-03-29 09:59:19 +0200 |
commit | 7f6b529a484c53341c65865e943e3dbfd61c6cd9 (patch) | |
tree | 177daf4afbfe0b7b6cfc7dbcbbc926fbaec8f89e /src/plugins | |
parent | bfcdd9c70077a282847170156b2261a98cdc24e0 (diff) | |
download | qt-creator-7f6b529a484c53341c65865e943e3dbfd61c6cd9.tar.gz |
debugger: Merge 'fork' and 'vfork' breakpoints
Reviewed-by: Friedemann Kleint
Diffstat (limited to 'src/plugins')
-rw-r--r-- | src/plugins/debugger/breakhandler.cpp | 6 | ||||
-rw-r--r-- | src/plugins/debugger/breakpoint.cpp | 2 | ||||
-rw-r--r-- | src/plugins/debugger/breakpoint.h | 2 | ||||
-rw-r--r-- | src/plugins/debugger/breakwindow.cpp | 20 | ||||
-rw-r--r-- | src/plugins/debugger/cdb/cdbengine.cpp | 2 | ||||
-rw-r--r-- | src/plugins/debugger/cdb/cdbparsehelpers.cpp | 7 | ||||
-rw-r--r-- | src/plugins/debugger/gdb/gdbengine.cpp | 8 |
7 files changed, 27 insertions, 20 deletions
diff --git a/src/plugins/debugger/breakhandler.cpp b/src/plugins/debugger/breakhandler.cpp index aabe0ebe18..2c1fa88874 100644 --- a/src/plugins/debugger/breakhandler.cpp +++ b/src/plugins/debugger/breakhandler.cpp @@ -106,8 +106,8 @@ static QString typeToString(BreakpointType type) return msgBreakpointAtSpecialFunc("fork"); case BreakpointAtExec: return msgBreakpointAtSpecialFunc("exec"); - case BreakpointAtVFork: - return msgBreakpointAtSpecialFunc("vfork"); + //case BreakpointAtVFork: + // return msgBreakpointAtSpecialFunc("vfork"); case BreakpointAtSysCall: return msgBreakpointAtSpecialFunc("syscall"); case BreakpointAtMain: @@ -512,7 +512,7 @@ QVariant BreakHandler::data(const QModelIndex &mi, int role) const || data.type == BreakpointAtCatch || data.type == BreakpointAtFork || data.type == BreakpointAtExec - || data.type == BreakpointAtVFork + //|| data.type == BreakpointAtVFork || data.type == BreakpointAtSysCall) return typeToString(data.type); if (data.type == Watchpoint) diff --git a/src/plugins/debugger/breakpoint.cpp b/src/plugins/debugger/breakpoint.cpp index 8a6c69b5dd..d0e60aac9d 100644 --- a/src/plugins/debugger/breakpoint.cpp +++ b/src/plugins/debugger/breakpoint.cpp @@ -107,7 +107,7 @@ QString BreakpointParameters::toString() const case BreakpointAtMain: case BreakpointAtFork: case BreakpointAtExec: - case BreakpointAtVFork: + //case BreakpointAtVFork: case BreakpointAtSysCall: case UnknownType: break; diff --git a/src/plugins/debugger/breakpoint.h b/src/plugins/debugger/breakpoint.h index 6c85561cfa..0a0941e607 100644 --- a/src/plugins/debugger/breakpoint.h +++ b/src/plugins/debugger/breakpoint.h @@ -61,7 +61,7 @@ enum BreakpointType BreakpointAtMain, BreakpointAtFork, BreakpointAtExec, - BreakpointAtVFork, + //BreakpointAtVFork, BreakpointAtSysCall, Watchpoint }; diff --git a/src/plugins/debugger/breakwindow.cpp b/src/plugins/debugger/breakwindow.cpp index 1ce02e0893..3eb357ecd4 100644 --- a/src/plugins/debugger/breakwindow.cpp +++ b/src/plugins/debugger/breakwindow.cpp @@ -122,12 +122,16 @@ BreakpointDialog::BreakpointDialog(unsigned engineCapabilities, QWidget *parent) // Match BreakpointType (omitting unknown type). m_ui.setupUi(this); QStringList types; - types << tr("File and Line Number") << tr("Function Name") << tr("Address") - << tr("throw") << tr("catch") - << tr("Function \"main()\"") - << tr("fork") << tr("exec") - << tr("vfork") << tr("syscall") - << tr("Address (Watchpoint)"); + types << tr("File and Line Number") + << tr("Function Name") + << tr("Address") + << tr("Break when C++ Exception is Thrown") + << tr("Break when C++ Exception is Caught") + << tr("Break when Function \"main()\" Starts") + << tr("Break when a new Process is Forked") + << tr("Break when a new Process is Executed") + << tr("Break when a System Call is Executed") + << tr("Break on Data Access (Watchpoint)"); QTC_ASSERT(types.size() == Watchpoint, return; ) m_ui.comboBoxType->addItems(types); m_ui.pathChooserFileName->setExpectedKind(Utils::PathChooser::File); @@ -339,7 +343,7 @@ void BreakpointDialog::typeChanged(int) case BreakpointAtMain: case BreakpointAtFork: case BreakpointAtExec: - case BreakpointAtVFork: + //case BreakpointAtVFork: case BreakpointAtSysCall: break; case BreakpointByAddress: @@ -366,7 +370,7 @@ void BreakpointDialog::typeChanged(int) case BreakpointAtCatch: case BreakpointAtFork: case BreakpointAtExec: - case BreakpointAtVFork: + //case BreakpointAtVFork: case BreakpointAtSysCall: clearOtherParts(AllConditionParts|ModulePart|TracePointPart); setPartsEnabled(AllConditionParts|TracePointPart); diff --git a/src/plugins/debugger/cdb/cdbengine.cpp b/src/plugins/debugger/cdb/cdbengine.cpp index 949bed5fb4..a36300fbb4 100644 --- a/src/plugins/debugger/cdb/cdbengine.cpp +++ b/src/plugins/debugger/cdb/cdbengine.cpp @@ -2283,7 +2283,7 @@ bool CdbEngine::acceptsBreakpoint(BreakpointId id) const switch (data.type) { case UnknownType: case BreakpointAtFork: - case BreakpointAtVFork: + //case BreakpointAtVFork: case BreakpointAtSysCall: return false; case Watchpoint: diff --git a/src/plugins/debugger/cdb/cdbparsehelpers.cpp b/src/plugins/debugger/cdb/cdbparsehelpers.cpp index 736ea512c9..446e50abf0 100644 --- a/src/plugins/debugger/cdb/cdbparsehelpers.cpp +++ b/src/plugins/debugger/cdb/cdbparsehelpers.cpp @@ -102,7 +102,7 @@ static BreakpointParameters fixWinMSVCBreakpoint(const BreakpointParameters &p) case BreakpointByFunction: case BreakpointByAddress: case BreakpointAtFork: - case BreakpointAtVFork: + //case BreakpointAtVFork: case BreakpointAtSysCall: case Watchpoint: break; @@ -144,7 +144,8 @@ QByteArray cdbAddBreakpointCommand(const BreakpointParameters &bpIn, str << '~' << bp.threadSpec << ' '; // Currently use 'bu' so that the offset expression (including file name) - // is kept when reporting back breakpoints (which is otherwise discarded when resolving). + // is kept when reporting back breakpoints (which is otherwise discarded + // when resolving). str << (bp.type == Watchpoint ? "ba" : "bu"); if (id != BreakpointId(-1)) str << id; @@ -154,7 +155,7 @@ QByteArray cdbAddBreakpointCommand(const BreakpointParameters &bpIn, switch (bp.type) { case BreakpointAtFork: case BreakpointAtExec: - case BreakpointAtVFork: + //case BreakpointAtVFork: case BreakpointAtSysCall: case UnknownType: case BreakpointAtCatch: diff --git a/src/plugins/debugger/gdb/gdbengine.cpp b/src/plugins/debugger/gdb/gdbengine.cpp index 9fad46fdd7..0180c3e881 100644 --- a/src/plugins/debugger/gdb/gdbengine.cpp +++ b/src/plugins/debugger/gdb/gdbengine.cpp @@ -2685,13 +2685,15 @@ void GdbEngine::insertBreakpoint(BreakpointId id) if (type == BreakpointAtFork) { postCommand("catch fork", NeedsStop | RebuildBreakpointModel, CB(handleCatchInsert), id); - return; - } - if (type == BreakpointAtVFork) { postCommand("catch vfork", NeedsStop | RebuildBreakpointModel, CB(handleCatchInsert), id); return; } + //if (type == BreakpointAtVFork) { + // postCommand("catch vfork", NeedsStop | RebuildBreakpointModel, + // CB(handleCatchInsert), id); + // return; + //} if (type == BreakpointAtExec) { postCommand("catch exec", NeedsStop | RebuildBreakpointModel, CB(handleCatchInsert), id); |