1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-08-22 07:43:56 +02:00

Do not Disable the events. Part of FIX for 46313

This commit is contained in:
Alain Magloire 2003-11-20 22:22:22 +00:00
parent 0865df6aef
commit 0abe445974

View file

@ -25,7 +25,6 @@ import org.eclipse.cdt.debug.mi.core.MISession;
import org.eclipse.cdt.debug.mi.core.cdi.model.Breakpoint;
import org.eclipse.cdt.debug.mi.core.cdi.model.Target;
import org.eclipse.cdt.debug.mi.core.cdi.model.Watchpoint;
import org.eclipse.cdt.debug.mi.core.command.Command;
import org.eclipse.cdt.debug.mi.core.command.CommandFactory;
import org.eclipse.cdt.debug.mi.core.command.MIBreakAfter;
import org.eclipse.cdt.debug.mi.core.command.MIBreakCondition;
@ -103,23 +102,14 @@ public class BreakpointManager extends SessionObject implements ICDIBreakpointMa
boolean suspendInferior(ICDITarget target) throws CDIException {
boolean shouldRestart = false;
Session session = (Session)getSession();
// Stop the program
if (allowInterrupt) {
if (target instanceof Target) {
Target ctarget = (Target)target;
// Disable events.
if (ctarget.isRunning()) {
EventManager mgr = (EventManager)session.getEventManager();
Command cmd = ctarget.getLastExecutionCommand();
int lastToken = 0;
if (cmd != null) {
lastToken = cmd.getToken();
}
mgr.disableEventToken(lastToken);
ctarget.suspend();
shouldRestart = true;
mgr.enableEventToken(lastToken);
}
} else if (!target.isSuspended()) {
target.suspend();