Skip to content

Commit e1a3505

Browse files
authored
fix the InvalidStackFrameException (#233)
1 parent 81fc9a5 commit e1a3505

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

com.microsoft.java.debug.core/src/main/java/com/microsoft/java/debug/core/adapter/handler/SetBreakpointsRequestHandler.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -193,11 +193,12 @@ private void registerBreakpointHandler(IDebugAdapterContext context) {
193193
CompletableFuture.runAsync(() -> {
194194
engine.evaluateForBreakpoint((IEvaluatableBreakpoint) expressionBP, bpThread).whenComplete((value, ex) -> {
195195
boolean resume = handleEvaluationResult(context, bpThread, expressionBP, value, ex);
196+
// Clear the evaluation environment caused by above evaluation.
197+
engine.clearState(bpThread);
198+
196199
if (resume) {
197200
debugEvent.eventSet.resume();
198201
}
199-
// Clear the evaluation environment caused by above evaluation.
200-
engine.clearState(bpThread);
201202
});
202203
});
203204
} else {

0 commit comments

Comments
 (0)