From d8253db6e6c5a4bdfe055f9482208fafacb056a3 Mon Sep 17 00:00:00 2001 From: Mikhail Khodjaiants Date: Thu, 2 Jan 2003 16:38:44 +0000 Subject: [PATCH] Fix for breakpoints disabled before launching. --- debug/org.eclipse.cdt.debug.core/ChangeLog | 6 +++++- .../cdt/debug/internal/core/model/CDebugTarget.java | 11 ++++++++--- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/debug/org.eclipse.cdt.debug.core/ChangeLog b/debug/org.eclipse.cdt.debug.core/ChangeLog index 04658940d26..bbc6a7fd741 100644 --- a/debug/org.eclipse.cdt.debug.core/ChangeLog +++ b/debug/org.eclipse.cdt.debug.core/ChangeLog @@ -1,4 +1,8 @@ -2002-12-18 Mikhail Khodjaiants +2003-01-02 Mikhail Khodjaiants + If breakpoint or watchpoint has been disabled before launching the debugger doesn't disable it. + * CDebugTarget.java + +2002-12-29 Mikhail Khodjaiants Implementation of the 'Source Lookup' property page. * IDirectorySourceLocation.java: new interface * IProjectSourceLocation.java: new interface diff --git a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CDebugTarget.java b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CDebugTarget.java index 04525947d81..ed2a7e22403 100644 --- a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CDebugTarget.java +++ b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CDebugTarget.java @@ -1591,9 +1591,6 @@ public class CDebugTarget extends CDebugElement ICDIBreakpointManager bm = getCDISession().getBreakpointManager(); try { - // FIXME: We should make sure that the parent folder where we - // want to set the breakpoint is added to the list of source directory. - // where the debugger looks for files. ICDILocation location = bm.createLocation( breakpoint.getMarker().getResource().getLocation().lastSegment(), null, breakpoint.getLineNumber() ); ICDICondition condition = bm.createCondition( breakpoint.getIgnoreCount(), breakpoint.getCondition() ); ICDIBreakpoint cdiBreakpoint = bm.setLocationBreakpoint( ICDIBreakpoint.REGULAR, location, condition, null ); @@ -1601,6 +1598,10 @@ public class CDebugTarget extends CDebugElement { getBreakpoints().put( breakpoint, cdiBreakpoint ); ((CBreakpoint)breakpoint).incrementInstallCount(); + if ( !breakpoint.isEnabled() ) + { + cdiBreakpoint.setEnabled( false ); + } } } catch( CoreException ce ) @@ -1628,6 +1629,10 @@ public class CDebugTarget extends CDebugElement { getBreakpoints().put( watchpoint, cdiWatchpoint ); ((CBreakpoint)watchpoint).incrementInstallCount(); + if ( !watchpoint.isEnabled() ) + { + cdiWatchpoint.setEnabled( false ); + } } } catch( CoreException ce )