diff --git a/debug/org.eclipse.cdt.debug.core/ChangeLog b/debug/org.eclipse.cdt.debug.core/ChangeLog index 49eb42fb739..944fab8b004 100644 --- a/debug/org.eclipse.cdt.debug.core/ChangeLog +++ b/debug/org.eclipse.cdt.debug.core/ChangeLog @@ -1,3 +1,7 @@ +2005-11-07 Mikhail Khodjaiants + Bug 115385: Pointer to a structure is not updated correctly + * CVariable.java + 2005-10-24 Mikhail Khodjaiants Fix for bugs 112008 and 111828. Applied modified patch from Matthias Spycher (matthias@coware.com). diff --git a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CVariable.java b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CVariable.java index 66ffbd70fe2..c91cede0994 100644 --- a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CVariable.java +++ b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CVariable.java @@ -533,6 +533,11 @@ public abstract class CVariable extends AbstractCVariable implements ICDIEventLi */ public boolean equals( Object obj ) { if ( obj instanceof CVariable ) { + // A disposed copy can be stored in the viewer. + // false should be returned to force the viewer to + // replace it by a new variable. See bug #115385 + if ( isDisposed() != ((CVariable)obj).isDisposed() ) + return false; IInternalVariable iv = getOriginal(); return ( iv != null ) ? iv.equals( ((CVariable)obj).getOriginal() ) : false; }