Project: JDT
Bug 184971 Four leaked images switching models in sync view
Reported: 2007-05-01 16:14:19 | Status: verified fixed

Build: I20070501-0010 1) Open synchronize view so it has various incoming changes on Java projects 2) Make sure view is initially showing "All Models" 3) Capture snapshot with Sleak 4) Switch to "Change Sets" model in drop down menu 5) Switch back to "All Models" Each time steps 4-5 are repeated, four more images are leaked. The images are not reclaimed when the synchronize view is closed. The allocation stack traces for these images are all the same: java.lang.Error at java.lang.Throwable.<init>(Throwable.java:56) at org.eclipse.swt.graphics.Device.new_Object(Device.java:787) at org.eclipse.swt.graphics.Image.<init>(Image.java:491) at org.eclipse.jface.resource.ImageDescriptor.createImage(ImageDescriptor.java:289) at org.eclipse.jface.resource.ImageDescriptor.createImage(ImageDescriptor.java:227) at org.eclipse.jface.resource.ImageDescriptor.createImage(ImageDescriptor.java:205) at org.eclipse.ltk.ui.refactoring.history.RefactoringHistoryLabelProvider.<init>(RefactoringHistoryLabelProvider.java:97) at org.eclipse.jdt.internal.ui.model.JavaModelLabelProvider.<init>(JavaModelLabelProvider.java:41) at org.eclipse.jdt.internal.ui.model.JavaSynchronizationLabelProvider.getDelegateLabelProvider(JavaSynchronizationLabelProvider.java:86) at org.eclipse.team.ui.synchronize.AbstractSynchronizeLabelProvider.addListener(AbstractSynchronizeLabelProvider.java:182) at org.eclipse.ui.internal.navigator.extensions.NavigatorContentExtension.getLabelProvider(NavigatorContentExtension.java:185) at org.eclipse.ui.internal.navigator.NavigatorContentServiceLabelProvider.findUpdateLabel(NavigatorContentServiceLabelProvider.java:321) at org.eclipse.ui.internal.navigator.NavigatorContentServiceLabelProvider.updateLabel(NavigatorContentServiceLabelProvider.java:309) at org.eclipse.jface.viewers.DecoratingLabelProvider.updateLabel(DecoratingLabelProvider.java:345) at org.eclipse.jface.viewers.DecoratingLabelProvider.updateLabel(DecoratingLabelProvider.java:345) at org.eclipse.jface.viewers.WrappedViewerLabelProvider.update(WrappedViewerLabelProvider.java:185) at org.eclipse.jface.viewers.ViewerColumn.refresh(ViewerColumn.java:135) at org.eclipse.jface.viewers.AbstractTreeViewer.doUpdateItem(AbstractTreeViewer.java:888) at org.eclipse.jface.viewers.AbstractTreeViewer$UpdateItemSafeRunnable.run(AbstractTreeViewer.java:97) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at org.eclipse.core.runtime.Platform.run(Platform.java:850) at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:45) at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:187) at org.eclipse.jface.viewers.AbstractTreeViewer.doUpdateItem(AbstractTreeViewer.java:963) at org.eclipse.jface.viewers.StructuredViewer$UpdateItemSafeRunnable.run(StructuredViewer.java:466) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at org.eclipse.core.runtime.Platform.run(Platform.java:850) at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:45) at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:187) at org.eclipse.jface.viewers.StructuredViewer.updateItem(StructuredViewer.java:2014) at org.eclipse.jface.viewers.AbstractTreeViewer.createTreeItem(AbstractTreeViewer.java:799) at org.eclipse.ui.navigator.CommonViewer.createTreeItem(CommonViewer.java:150) at org.eclipse.jface.viewers.AbstractTreeViewer$1.run(AbstractTreeViewer.java:777) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:67) at org.eclipse.jface.viewers.AbstractTreeViewer.createChildren(AbstractTreeViewer.java:751) at org.eclipse.jface.viewers.TreeViewer.createChildren(TreeViewer.java:553) at org.eclipse.jface.viewers.AbstractTreeViewer.internalInitializeTree(AbstractTreeViewer.java:1420) at org.eclipse.jface.viewers.TreeViewer.internalInitializeTree(TreeViewer.java:742) at org.eclipse.jface.viewers.AbstractTreeViewer$5.run(AbstractTreeViewer.java:1407) at org.eclipse.jface.viewers.StructuredViewer.preservingSelection(StructuredViewer.java:1363) at org.eclipse.jface.viewers.TreeViewer.preservingSelection(TreeViewer.java:377) at org.eclipse.jface.viewers.StructuredViewer.preservingSelection(StructuredViewer.java:1325) at org.eclipse.jface.viewers.AbstractTreeViewer.inputChanged(AbstractTreeViewer.java:1396) at org.eclipse.team.internal.ui.mapping.CommonViewerAdvisor$NavigableCommonViewer.inputChanged(CommonViewerAdvisor.java:83) at org.eclipse.jface.viewers.ContentViewer.setInput(ContentViewer.java:251) at org.eclipse.jface.viewers.StructuredViewer.setInput(StructuredViewer.java:1601) at org.eclipse.team.internal.ui.mapping.CommonViewerAdvisor$4.run(CommonViewerAdvisor.java:474) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:67) at org.eclipse.team.internal.ui.Utils$6.run(Utils.java:790) at org.eclipse.swt.widgets.Synchronizer.syncExec(Synchronizer.java:152) at org.eclipse.ui.internal.UISynchronizer.syncExec(UISynchronizer.java:118) at org.eclipse.swt.widgets.Display.syncExec(Display.java:4088) at org.eclipse.team.internal.ui.Utils.syncExec(Utils.java:787) at org.eclipse.team.internal.ui.Utils.syncExec(Utils.java:782) at org.eclipse.team.internal.ui.mapping.CommonViewerAdvisor.propertyChange(CommonViewerAdvisor.java:470) at org.eclipse.team.internal.ui.synchronize.SynchronizePageConfiguration$1.run(SynchronizePageConfiguration.java:242) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at org.eclipse.team.internal.ui.synchronize.SynchronizePageConfiguration.firePropertyChange(SynchronizePageConfiguration.java:237) at org.eclipse.team.internal.ui.synchronize.SynchronizePageConfiguration.setProperty(SynchronizePageConfiguration.java:184) at org.eclipse.team.internal.ui.mapping.ModelSelectionDropDownAction$2.run(ModelSelectionDropDownAction.java:89) at org.eclipse.jface.action.Action.runWithEvent(Action.java:498) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:545) at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:490) at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:402) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:938) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3673) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3284) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2365) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2329) at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2204) at org.eclipse.ui.internal.Workbench$4.run(Workbench.java:466) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:289) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:461) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149) at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:101) at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:153) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:106) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:76) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:363) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:176) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:615) at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:480) at org.eclipse.equinox.launcher.Main.basicRun(Main.java:419) at org.eclipse.equinox.launcher.Main.run(Main.java:1145) at org.eclipse.equinox.launcher.Main.main(Main.java:1120)

Files changed in fix:
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/model/JavaSynchronizationLabelProvider.java