Bug 142785 NavigatorSaveablesServices NPEs on shutdown
On Build id: I20060505-1306: The following exception was encountered on shutdown, and encountered multiple times (about 20). I'm not sure I have a scenario that can reproduce this, but there were many more Navigator extensions than base platform (roughly 20). I think by the time this was reached, the Project Explorer had been disposed. !ENTRY org.eclipse.osgi 4 0 2006-05-19 11:21:38.993 !MESSAGE An unexpected runtime error has occurred. !STACK 0 java.lang.NullPointerException at org.eclipse.ui.internal.navigator.NavigatorSaveablesService.computeSaveables(NavigatorSaveablesService.java:216) at org.eclipse.ui.internal.navigator.NavigatorSaveablesService.recomputeSaveablesAndNotify(NavigatorSaveablesService.java:374) at org.eclipse.ui.internal.navigator.NavigatorSaveablesService.handleBundleStopped(NavigatorSaveablesService.java:457) at org.eclipse.ui.internal.navigator.NavigatorSaveablesService.bundleChanged(NavigatorSaveablesService.java:100) at org.eclipse.ui.internal.navigator.NavigatorPlugin$1.bundleChanged(NavigatorPlugin.java:35) at org.eclipse.osgi.framework.internal.core.BundleContextImpl.dispatchEvent(BundleContextImpl.java:1206) at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:189) at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:291) 11
bundles/org.eclipse.ui.navigator/src/org/eclipse/ui/navigator/CommonViewer.java
NavigatorPipelineService pipeDream = (NavigatorPipelineService) contentService
				.getPipelineService();
		PipelinedShapeModification modification = new PipelinedShapeModification(
				null, new ContributorTrackingSet(contentService, elements));
		pipeDream.interceptRemove(modification);
		super.remove(modification.getChildren().toArray());
	}
	/*
	 * (non-Javadoc)
	 * 
	 * @see org.eclipse.jface.viewers.StructuredViewer#refresh(java.lang.Object,
	 *      boolean)
	 */
	public void refresh(Object element, boolean updateLabels) {
		
		if(element != getInput()) {
		
			INavigatorPipelineService pipeDream = contentService
					.getPipelineService();
	
			PipelinedViewerUpdate update = new PipelinedViewerUpdate();
			update.getRefreshTargets().add(element);
			update.setUpdateLabels(updateLabels);
			
			if (pipeDream.interceptRefresh(update)) {
				
				boolean toUpdateLabels = update.isUpdateLabels();
				for (Iterator iter = update.getRefreshTargets().iterator(); iter
						.hasNext();) {
					super.refresh(iter.next(), toUpdateLabels);