Project: JDT
Bug 91809 Packages view throws NPE on creation
Reported: 2005-04-18 19:05:44 | Status: resolved fixed

Running with code in HEAD, 20050418 Switch to the Java Browsing perspective. I get: java.lang.NullPointerException at org.eclipse.jdt.internal.ui.browsing.PackagesView.findInputForJavaElement(PackagesView.java:545) at org.eclipse.jdt.internal.ui.browsing.JavaBrowsingPart.setInitialInput(JavaBrowsingPart.java:898) at org.eclipse.jdt.internal.ui.browsing.JavaBrowsingPart.createPartControl(JavaBrowsingPart.java:374) at org.eclipse.ui.internal.ViewReference.createPartHelper(ViewReference.java:305) at org.eclipse.ui.internal.ViewReference.createPart(ViewReference.java:182) at org.eclipse.ui.internal.WorkbenchPartReference.getPart(WorkbenchPartReference.java:492) at org.eclipse.ui.internal.PartPane.setVisible(PartPane.java:265) at org.eclipse.ui.internal.ViewPane.setVisible(ViewPane.java:514) at org.eclipse.ui.internal.presentations.PresentablePart.setVisible(PresentablePart.java:126) at org.eclipse.ui.internal.presentations.newapi.PresentablePartFolder.select(PresentablePartFolder.java:268) at org.eclipse.ui.internal.presentations.newapi.LeftToRightTabOrder.select(LeftToRightTabOrder.java:65) at org.eclipse.ui.internal.presentations.newapi.TabbedStackPresentation.selectPart(TabbedStackPresentation.java:391) at org.eclipse.ui.internal.PartStack.refreshPresentationSelection(PartStack.java:1064) at org.eclipse.ui.internal.PartStack.createControl(PartStack.java:552) at org.eclipse.ui.internal.PartStack.createControl(PartStack.java:489) at org.eclipse.ui.internal.PartSashContainer.createControl(PartSashContainer.java:485) at org.eclipse.ui.internal.PerspectiveHelper.activate(PerspectiveHelper.java:230) at org.eclipse.ui.internal.Perspective.onActivate(Perspective.java:781) at org.eclipse.ui.internal.WorkbenchPage.setPerspective(WorkbenchPage.java:2742) at org.eclipse.ui.internal.WorkbenchPage.busySetPerspective(WorkbenchPage.java:870) at org.eclipse.ui.internal.WorkbenchPage.access$9(WorkbenchPage.java:855) at org.eclipse.ui.internal.WorkbenchPage$12.run(WorkbenchPage.java:2864) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:69) at org.eclipse.ui.internal.WorkbenchPage.setPerspective(WorkbenchPage.java:2862) at org.eclipse.ui.internal.PerspectiveBarContributionItem.select(PerspectiveBarContributionItem.java:109) at org.eclipse.ui.internal.PerspectiveBarContributionItem$1.widgetSelected(PerspectiveBarContributionItem.java:81) at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:89) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:82) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:842) at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:2897) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2530) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1570) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1534) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:306) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:143) at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:103) at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:228) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:156) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at org.eclipse.core.launcher.Main.invokeFramework(Main.java:319) at org.eclipse.core.launcher.Main.basicRun(Main.java:272) at org.eclipse.core.launcher.Main.run(Main.java:951) at org.eclipse.core.launcher.Main.main(Main.java:935)

Files changed in fix:
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/PackagesView.java