diff options
author | eutarass | 2011-01-27 01:12:04 +0000 |
---|---|---|
committer | eutarass | 2011-01-27 01:12:04 +0000 |
commit | 9870814794285a954b55bb8bd3af13e7c232604b (patch) | |
tree | b77956bbb2dafe38cf082f69ed460c40b099cf71 | |
parent | ed6224413814b52506683a6f3061a7eae7928955 (diff) | |
download | org.eclipse.tcf-9870814794285a954b55bb8bd3af13e7c232604b.tar.gz org.eclipse.tcf-9870814794285a954b55bb8bd3af13e7c232604b.tar.xz org.eclipse.tcf-9870814794285a954b55bb8bd3af13e7c232604b.zip |
TCF Debugger: slightly better way to check that debug context reached temporary breakpoint in "step out" and "step over" command handlers
2 files changed, 16 insertions, 12 deletions
diff --git a/plugins/org.eclipse.tm.tcf.debug/src/org/eclipse/tm/internal/tcf/debug/actions/TCFActionStepOut.java b/plugins/org.eclipse.tm.tcf.debug/src/org/eclipse/tm/internal/tcf/debug/actions/TCFActionStepOut.java index b5b4e7140..c1028f8fa 100644 --- a/plugins/org.eclipse.tm.tcf.debug/src/org/eclipse/tm/internal/tcf/debug/actions/TCFActionStepOut.java +++ b/plugins/org.eclipse.tm.tcf.debug/src/org/eclipse/tm/internal/tcf/debug/actions/TCFActionStepOut.java @@ -198,14 +198,16 @@ public abstract class TCFActionStepOut extends TCFAction implements IRunControl. private boolean isMyBreakpoint(TCFContextState state_data) { if (bp == null) return false; - if (state_data.suspend_pc == null) return false; if (!IRunControl.REASON_BREAKPOINT.equals(state_data.suspend_reason)) return false; - Object ids = state_data.suspend_params.get(IRunControl.STATE_BREAKPOINT_IDS); - if (ids != null) { - @SuppressWarnings("unchecked") - Collection<String> c = (Collection<String>)ids; - if (c.contains(bp.get(IBreakpoints.PROP_ID))) return true; + if (state_data.suspend_params != null) { + Object ids = state_data.suspend_params.get(IRunControl.STATE_BREAKPOINT_IDS); + if (ids != null) { + @SuppressWarnings("unchecked") + Collection<String> c = (Collection<String>)ids; + if (c.contains(bp.get(IBreakpoints.PROP_ID))) return true; + } } + if (state_data.suspend_pc == null) return false; BigInteger x = new BigInteger(state_data.suspend_pc); BigInteger y = new BigInteger((String)bp.get(IBreakpoints.PROP_LOCATION)); return x.equals(y); diff --git a/plugins/org.eclipse.tm.tcf.debug/src/org/eclipse/tm/internal/tcf/debug/actions/TCFActionStepOver.java b/plugins/org.eclipse.tm.tcf.debug/src/org/eclipse/tm/internal/tcf/debug/actions/TCFActionStepOver.java index ca3e41d69..b5518bd89 100644 --- a/plugins/org.eclipse.tm.tcf.debug/src/org/eclipse/tm/internal/tcf/debug/actions/TCFActionStepOver.java +++ b/plugins/org.eclipse.tm.tcf.debug/src/org/eclipse/tm/internal/tcf/debug/actions/TCFActionStepOver.java @@ -352,14 +352,16 @@ public abstract class TCFActionStepOver extends TCFAction implements IRunControl private boolean isMyBreakpoint(TCFContextState state_data) { if (bp == null) return false; - if (state_data.suspend_pc == null) return false; if (!IRunControl.REASON_BREAKPOINT.equals(state_data.suspend_reason)) return false; - Object ids = state_data.suspend_params.get(IRunControl.STATE_BREAKPOINT_IDS); - if (ids != null) { - @SuppressWarnings("unchecked") - Collection<String> c = (Collection<String>)ids; - if (c.contains(bp.get(IBreakpoints.PROP_ID))) return true; + if (state_data.suspend_params != null) { + Object ids = state_data.suspend_params.get(IRunControl.STATE_BREAKPOINT_IDS); + if (ids != null) { + @SuppressWarnings("unchecked") + Collection<String> c = (Collection<String>)ids; + if (c.contains(bp.get(IBreakpoints.PROP_ID))) return true; + } } + if (state_data.suspend_pc == null) return false; BigInteger x = new BigInteger(state_data.suspend_pc); BigInteger y = new BigInteger((String)bp.get(IBreakpoints.PROP_LOCATION)); return x.equals(y); |