mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
allow no more than one suspend context with suspend policy 'suspend_all'
This commit is contained in:
@@ -178,8 +178,19 @@ public class DebugProcessEvents extends DebugProcessImpl {
|
||||
|
||||
getManagerThread().invokeAndWait(new DebuggerCommandImpl() {
|
||||
protected void action() throws Exception {
|
||||
|
||||
if (eventSet.suspendPolicy() == EventRequest.SUSPEND_ALL) {
|
||||
// check if there is already one request with policy SUSPEND_ALL
|
||||
for (SuspendContextImpl context : getSuspendManager().getEventContexts()) {
|
||||
if (context.getSuspendPolicy() == EventRequest.SUSPEND_ALL) {
|
||||
eventSet.resume();
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
final SuspendContextImpl suspendContext = getSuspendManager().pushSuspendContext(eventSet);
|
||||
|
||||
|
||||
for (EventIterator eventIterator = eventSet.eventIterator(); eventIterator.hasNext();) {
|
||||
final Event event = eventIterator.nextEvent();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user