Skip to content

Commit 17868e8

Browse files
committed
Fixed isDebuggerSuspended check
It could throw a NPE in some exceptional cases when the debugger is stopped.
1 parent 957b8f2 commit 17868e8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

External/Plugins/FlashDebugger/Helpers/MenusHelper.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,7 @@ public void UpdateMenuState(object sender, DebuggerState state)
267267
CurrentButton.Enabled = CurrentMenu.Enabled = RunToCursorButton.Enabled = enabled;
268268
NextButton.Enabled = NextMenu.Enabled = FinishButton.Enabled = FinishMenu.Enabled = enabled;
269269
RunToCursorMenu.Enabled = StepButton.Enabled = StepMenu.Enabled = enabled;
270-
if (state == DebuggerState.Running && !PluginMain.debugManager.FlashInterface.isDebuggerSuspended)
270+
if (state == DebuggerState.Running && (!PluginMain.debugManager.FlashInterface.isDebuggerStarted || !PluginMain.debugManager.FlashInterface.isDebuggerSuspended))
271271
{
272272
PanelsHelper.localsUI.TreeControl.Nodes.Clear();
273273
PanelsHelper.stackframeUI.ClearItem();

0 commit comments

Comments
 (0)