From 63dc1031e92d48540f237e65dbc30ce5429bc0b6 Mon Sep 17 00:00:00 2001 From: Mikhail Khodjaiants Date: Wed, 12 May 2004 16:13:07 +0000 Subject: [PATCH] The input member of 'DisassemblyAnnotationModel' can be null. --- debug/org.eclipse.cdt.debug.ui/ChangeLog | 4 ++++ .../disassembly/DisassemblyAnnotationModel.java | 15 +++++++++------ 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/debug/org.eclipse.cdt.debug.ui/ChangeLog b/debug/org.eclipse.cdt.debug.ui/ChangeLog index 123638d8597..2c73e853025 100644 --- a/debug/org.eclipse.cdt.debug.ui/ChangeLog +++ b/debug/org.eclipse.cdt.debug.ui/ChangeLog @@ -1,3 +1,7 @@ +2004-05-12 Mikhail Khodjaiants + The input member of 'DisassemblyAnnotationModel' can be null. + * DisassemblyAnnotationModel.java + 2004-05-12 Mikhail Khodjaiants Do not log CoreException thrown from the 'decrementInstallCount' method. * CBreakpointUpdater.java diff --git a/debug/org.eclipse.cdt.debug.ui/src/org/eclipse/cdt/debug/internal/ui/views/disassembly/DisassemblyAnnotationModel.java b/debug/org.eclipse.cdt.debug.ui/src/org/eclipse/cdt/debug/internal/ui/views/disassembly/DisassemblyAnnotationModel.java index 85e64a1f9e2..decab51ae49 100644 --- a/debug/org.eclipse.cdt.debug.ui/src/org/eclipse/cdt/debug/internal/ui/views/disassembly/DisassemblyAnnotationModel.java +++ b/debug/org.eclipse.cdt.debug.ui/src/org/eclipse/cdt/debug/internal/ui/views/disassembly/DisassemblyAnnotationModel.java @@ -45,8 +45,9 @@ public class DisassemblyAnnotationModel extends AnnotationModel { } protected void breakpointsAdded( final IBreakpoint[] breakpoints, final IDocument document ) { - if ( getInput().equals( DisassemblyEditorInput.EMPTY_EDITOR_INPUT ) || - getInput().equals( DisassemblyEditorInput.PENDING_EDITOR_INPUT ) ) + DisassemblyEditorInput input = getInput(); + if ( DisassemblyEditorInput.EMPTY_EDITOR_INPUT.equals( input ) || + DisassemblyEditorInput.PENDING_EDITOR_INPUT.equals( input ) ) return; asyncExec( new Runnable() { public void run() { @@ -56,8 +57,9 @@ public class DisassemblyAnnotationModel extends AnnotationModel { } protected void breakpointsRemoved( final IBreakpoint[] breakpoints, final IDocument document ) { - if ( getInput().equals( DisassemblyEditorInput.EMPTY_EDITOR_INPUT ) || - getInput().equals( DisassemblyEditorInput.PENDING_EDITOR_INPUT ) ) + DisassemblyEditorInput input = getInput(); + if ( DisassemblyEditorInput.EMPTY_EDITOR_INPUT.equals( input ) || + DisassemblyEditorInput.PENDING_EDITOR_INPUT.equals( input ) ) return; asyncExec( new Runnable() { public void run() { @@ -67,8 +69,9 @@ public class DisassemblyAnnotationModel extends AnnotationModel { } protected void breakpointsChanged( final IBreakpoint[] breakpoints, final IDocument document ) { - if ( getInput().equals( DisassemblyEditorInput.EMPTY_EDITOR_INPUT ) || - getInput().equals( DisassemblyEditorInput.PENDING_EDITOR_INPUT ) ) + DisassemblyEditorInput input = getInput(); + if ( DisassemblyEditorInput.EMPTY_EDITOR_INPUT.equals( input ) || + DisassemblyEditorInput.PENDING_EDITOR_INPUT.equals( input ) ) return; asyncExec( new Runnable() { public void run() {