From 812fe3f28a2bc94d5c1b27dce3aa478de796cf04 Mon Sep 17 00:00:00 2001 From: Alexey Merkulov Date: Tue, 9 Apr 2024 14:51:06 +0200 Subject: [PATCH] [debugger] IDEA-350602 Remove assertion: suspend-thread context can point to another thread while stepping in it Suppose, two threads (A and B) in suspend-thread mode are suspended and stepping performed in one of them (A). To avoid context switch, the debugger sets active execution stack in the context of the other suspended thread (B) to the thead performed stepping (A). So the removed assertion was not correct in this situation. GitOrigin-RevId: 684f73090982ceee6adc17227aa85326a4946805 --- .../src/com/intellij/debugger/engine/SuspendContextImpl.java | 3 --- 1 file changed, 3 deletions(-) diff --git a/java/debugger/impl/src/com/intellij/debugger/engine/SuspendContextImpl.java b/java/debugger/impl/src/com/intellij/debugger/engine/SuspendContextImpl.java index 02af61869dad..9509baf703b1 100644 --- a/java/debugger/impl/src/com/intellij/debugger/engine/SuspendContextImpl.java +++ b/java/debugger/impl/src/com/intellij/debugger/engine/SuspendContextImpl.java @@ -337,9 +337,6 @@ public abstract class SuspendContextImpl extends XSuspendContext implements Susp setThread(activeThread); } if (activeThread != null) { - if (getSuspendPolicy() == EventRequest.SUSPEND_EVENT_THREAD && activeThread != myThread) { - LOG.error("Context with suspend-thread policy must have only the corresponding myActiveExecutionStack"); - } myActiveExecutionStack = new JavaExecutionStack(activeThread, myDebugProcess, myThread == activeThread); myActiveExecutionStack.initTopFrame(); }