Project: JDT
Bug 94652 NPE when clearing Javadoc location property
Reported: 2005-05-11 06:49:00 | Status: resolved fixed

I20050509-2010 - changed the Javadoc location property for a project to a folder that doesn't contain a package-list.html - opened properties dialog again and emptied ythe location. - pressed OK java.lang.reflect.InvocationTargetException at org.eclipse.jface.operation.ModalContext.run(ModalContext.java:327) at org.eclipse.jface.dialogs.ProgressMonitorDialog.run(ProgressMonitorDialog.java:447) at org.eclipse.ui.internal.progress.ProgressMonitorJobsDialog.run(ProgressMonitorJobsDialog.java:261) at org.eclipse.ui.internal.progress.ProgressManager$3.run(ProgressManager.java:861) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:69) at org.eclipse.ui.internal.progress.ProgressManager.busyCursorWhile(ProgressManager.java:895) at org.eclipse.ui.internal.progress.ProgressManager.busyCursorWhile(ProgressManager.java:871) at org.eclipse.ui.internal.progress.ProgressManager.run(ProgressManager.java:1070) at org.eclipse.jdt.internal.ui.preferences.JavadocConfigurationPropertyPage.performOk(JavadocConfigurationPropertyPage.java:184) at org.eclipse.jface.preference.PreferenceDialog$11.run(PreferenceDialog.java:850) at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:1029) at org.eclipse.core.runtime.Platform.run(Platform.java:775) at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:44) at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:148) at org.eclipse.jface.preference.PreferenceDialog.okPressed(PreferenceDialog.java:830) at org.eclipse.ui.internal.dialogs.FilteredPreferenceDialog.okPressed(FilteredPreferenceDialog.java:295) at org.eclipse.jface.preference.PreferenceDialog.buttonPressed(PreferenceDialog.java:218) at org.eclipse.jface.dialogs.Dialog$2.widgetSelected(Dialog.java:556) 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:2901) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2534) at org.eclipse.jface.window.Window.runEventLoop(Window.java:803) at org.eclipse.jface.window.Window.open(Window.java:781) at org.eclipse.ui.dialogs.PropertyDialogAction.run(PropertyDialogAction.java:157) at org.eclipse.jface.action.Action.runWithEvent(Action.java:996) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:538) at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:488) at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:400) 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:2901) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2534) at org.eclipse.ui.internal.dialogs.EventLoopProgressMonitor.runEventLoop(EventLoopProgressMonitor.java:123) at org.eclipse.ui.internal.dialogs.EventLoopProgressMonitor.isCanceled(EventLoopProgressMonitor.java:97) at org.eclipse.core.internal.jobs.ThreadJob.isCanceled(ThreadJob.java:127) at org.eclipse.core.internal.jobs.ThreadJob.joinRun(ThreadJob.java:157) at org.eclipse.core.internal.jobs.ImplicitJobs.begin(ImplicitJobs.java:88) at org.eclipse.core.internal.jobs.JobManager.beginRule(JobManager.java:190) at org.eclipse.core.internal.resources.WorkManager.checkIn(WorkManager.java:96) at org.eclipse.core.internal.resources.Workspace.prepareOperation(Workspace.java:1671) at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1711) at org.eclipse.core.internal.resources.ProjectPreferences.save(ProjectPreferences.java:310) at org.eclipse.core.internal.preferences.EclipsePreferences.flush(EclipsePreferences.java:351) at org.eclipse.core.internal.resources.ProjectPreferences.flush(ProjectPreferences.java:530) at org.eclipse.ui.internal.preferences.WorkingCopyPreferences.flush(WorkingCopyPreferences.java:475) at org.eclipse.ui.internal.preferences.WorkingCopyManager.applyChanges(WorkingCopyManager.java:64) at org.eclipse.ui.internal.dialogs.FilteredPreferenceDialog.okPressed(FilteredPreferenceDialog.java:298) at org.eclipse.jface.preference.PreferenceDialog.buttonPressed(PreferenceDialog.java:218) at org.eclipse.jface.dialogs.Dialog$2.widgetSelected(Dialog.java:556) 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:2901) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2534) at org.eclipse.jface.window.Window.runEventLoop(Window.java:803) at org.eclipse.jface.window.Window.open(Window.java:781) at org.eclipse.ui.dialogs.PropertyDialogAction.run(PropertyDialogAction.java:157) at org.eclipse.jface.action.Action.runWithEvent(Action.java:996) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:538) at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:488) at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:400) 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:2901) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2534) at org.eclipse.ui.internal.dialogs.EventLoopProgressMonitor.runEventLoop(EventLoopProgressMonitor.java:123) at org.eclipse.ui.internal.dialogs.EventLoopProgressMonitor.isCanceled(EventLoopProgressMonitor.java:97) at org.eclipse.core.internal.jobs.ThreadJob.isCanceled(ThreadJob.java:127) at org.eclipse.core.internal.jobs.ThreadJob.joinRun(ThreadJob.java:157) at org.eclipse.core.internal.jobs.ImplicitJobs.begin(ImplicitJobs.java:88) at org.eclipse.core.internal.jobs.JobManager.beginRule(JobManager.java:190) at org.eclipse.core.internal.resources.WorkManager.checkIn(WorkManager.java:96) at org.eclipse.core.internal.resources.Workspace.prepareOperation(Workspace.java:1671) at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1711) at org.eclipse.core.internal.resources.ProjectPreferences.save(ProjectPreferences.java:310) at org.eclipse.core.internal.preferences.EclipsePreferences.flush(EclipsePreferences.java:351) at org.eclipse.core.internal.resources.ProjectPreferences.flush(ProjectPreferences.java:530) at org.eclipse.ui.internal.preferences.WorkingCopyPreferences.flush(WorkingCopyPreferences.java:475) at org.eclipse.ui.internal.preferences.WorkingCopyManager.applyChanges(WorkingCopyManager.java:64) at org.eclipse.ui.internal.dialogs.FilteredPreferenceDialog.okPressed(FilteredPreferenceDialog.java:298) at org.eclipse.jface.preference.PreferenceDialog.buttonPressed(PreferenceDialog.java:218) at org.eclipse.jface.dialogs.Dialog$2.widgetSelected(Dialog.java:556) 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:2901) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2534) at org.eclipse.jface.window.Window.runEventLoop(Window.java:803) at org.eclipse.jface.window.Window.open(Window.java:781) at org.eclipse.ui.dialogs.PropertyDialogAction.run(PropertyDialogAction.java:157) at org.eclipse.jface.action.Action.runWithEvent(Action.java:996) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:538) at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:488) at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:400) 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:2901) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2534) at org.eclipse.ui.internal.dialogs.EventLoopProgressMonitor.runEventLoop(EventLoopProgressMonitor.java:123) at org.eclipse.ui.internal.dialogs.EventLoopProgressMonitor.isCanceled(EventLoopProgressMonitor.java:97) at org.eclipse.core.internal.jobs.ThreadJob.isCanceled(ThreadJob.java:127) at org.eclipse.core.internal.jobs.ThreadJob.joinRun(ThreadJob.java:157) at org.eclipse.core.internal.jobs.ImplicitJobs.begin(ImplicitJobs.java:88) at org.eclipse.core.internal.jobs.JobManager.beginRule(JobManager.java:190) at org.eclipse.core.internal.resources.WorkManager.checkIn(WorkManager.java:96) at org.eclipse.core.internal.resources.Workspace.prepareOperation(Workspace.java:1671) at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1711) at org.eclipse.core.internal.resources.ProjectPreferences.save(ProjectPreferences.java:310) at org.eclipse.core.internal.preferences.EclipsePreferences.flush(EclipsePreferences.java:351) at org.eclipse.core.internal.resources.ProjectPreferences.flush(ProjectPreferences.java:530) at org.eclipse.ui.internal.preferences.WorkingCopyPreferences.flush(WorkingCopyPreferences.java:475) at org.eclipse.ui.internal.preferences.WorkingCopyManager.applyChanges(WorkingCopyManager.java:64) at org.eclipse.ui.internal.dialogs.FilteredPreferenceDialog.okPressed(FilteredPreferenceDialog.java:298) at org.eclipse.jface.preference.PreferenceDialog.buttonPressed(PreferenceDialog.java:218) at org.eclipse.jface.dialogs.Dialog$2.widgetSelected(Dialog.java:556) 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:2901) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2534) at org.eclipse.jface.window.Window.runEventLoop(Window.java:803) at org.eclipse.jface.window.Window.open(Window.java:781) at org.eclipse.ui.dialogs.PropertyDialogAction.run(PropertyDialogAction.java:157) at org.eclipse.jface.action.Action.runWithEvent(Action.java:996) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:538) at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:488) at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:400) 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:2901) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2534) at org.eclipse.ui.internal.dialogs.EventLoopProgressMonitor.runEventLoop(EventLoopProgressMonitor.java:123) at org.eclipse.ui.internal.dialogs.EventLoopProgressMonitor.isCanceled(EventLoopProgressMonitor.java:97) at org.eclipse.core.internal.jobs.ThreadJob.isCanceled(ThreadJob.java:127) at org.eclipse.core.internal.jobs.ThreadJob.joinRun(ThreadJob.java:157) at org.eclipse.core.internal.jobs.ImplicitJobs.begin(ImplicitJobs.java:88) at org.eclipse.core.internal.jobs.JobManager.beginRule(JobManager.java:190) at org.eclipse.core.internal.resources.WorkManager.checkIn(WorkManager.java:96) at org.eclipse.core.internal.resources.Workspace.prepareOperation(Workspace.java:1671) at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1711) at org.eclipse.core.internal.resources.ProjectPreferences.save(ProjectPreferences.java:310) at org.eclipse.core.internal.preferences.EclipsePreferences.flush(EclipsePreferences.java:351) at org.eclipse.core.internal.resources.ProjectPreferences.flush(ProjectPreferences.java:530) at org.eclipse.ui.internal.preferences.WorkingCopyPreferences.flush(WorkingCopyPreferences.java:475) at org.eclipse.ui.internal.preferences.WorkingCopyManager.applyChanges(WorkingCopyManager.java:64) at org.eclipse.ui.internal.dialogs.FilteredPreferenceDialog.okPressed(FilteredPreferenceDialog.java:298) at org.eclipse.jface.preference.PreferenceDialog.buttonPressed(PreferenceDialog.java:218) at org.eclipse.jface.dialogs.Dialog$2.widgetSelected(Dialog.java:556) 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:2901) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2534) at org.eclipse.jface.window.Window.runEventLoop(Window.java:803) at org.eclipse.jface.window.Window.open(Window.java:781) at org.eclipse.ui.dialogs.PropertyDialogAction.run(PropertyDialogAction.java:157) at org.eclipse.jface.action.Action.runWithEvent(Action.java:996) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:538) at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:488) at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:400) 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:2901) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2534) at org.eclipse.ui.internal.dialogs.EventLoopProgressMonitor.runEventLoop(EventLoopProgressMonitor.java:123) at org.eclipse.ui.internal.dialogs.EventLoopProgressMonitor.isCanceled(EventLoopProgressMonitor.java:97) at org.eclipse.core.internal.jobs.ThreadJob.isCanceled(ThreadJob.java:127) at org.eclipse.core.internal.jobs.ThreadJob.joinRun(ThreadJob.java:157) at org.eclipse.core.internal.jobs.ImplicitJobs.begin(ImplicitJobs.java:88) at org.eclipse.core.internal.jobs.JobManager.beginRule(JobManager.java:190) at org.eclipse.core.internal.resources.WorkManager.checkIn(WorkManager.java:96) at org.eclipse.core.internal.resources.Workspace.prepareOperation(Workspace.java:1671) at org.eclipse.core.internal.resources.Workspace.run(Workspace.java:1711) at org.eclipse.core.internal.resources.ProjectPreferences.save(ProjectPreferences.java:310) at org.eclipse.core.internal.preferences.EclipsePreferences.flush(EclipsePreferences.java:351) at org.eclipse.core.internal.resources.ProjectPreferences.flush(ProjectPreferences.java:530) at org.eclipse.ui.internal.preferences.WorkingCopyPreferences.flush(WorkingCopyPreferences.java:475) at org.eclipse.ui.internal.preferences.WorkingCopyManager.applyChanges(WorkingCopyManager.java:64) at org.eclipse.ui.internal.dialogs.FilteredPreferenceDialog.okPressed(FilteredPreferenceDialog.java:298) at org.eclipse.jface.preference.PreferenceDialog.buttonPressed(PreferenceDialog.java:218) at org.eclipse.jface.dialogs.Dialog$2.widgetSelected(Dialog.java:556) 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:2901) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2534) at org.eclipse.jface.window.Window.runEventLoop(Window.java:803) at org.eclipse.jface.window.Window.open(Window.java:781) at org.eclipse.ui.dialogs.PropertyDialogAction.run(PropertyDialogAction.java:157) at org.eclipse.jface.action.Action.runWithEvent(Action.java:996) at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:538) at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:488) at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:400) 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:2901) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2534) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1601) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1565) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:315) 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:230) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:345) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:158) 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:585) at org.eclipse.core.launcher.Main.invokeFramework(Main.java:328) at org.eclipse.core.launcher.Main.basicRun(Main.java:272) at org.eclipse.core.launcher.Main.run(Main.java:974) at org.eclipse.core.launcher.Main.main(Main.java:950) Caused by: java.lang.NullPointerException at org.eclipse.jdt.internal.corext.javadoc.JavaDocLocations.setProjectJavadocLocation(JavaDocLocations.java:233) at org.eclipse.jdt.ui.JavaUI.setProjectJavadocLocation(JavaUI.java:770) at org.eclipse.jdt.internal.ui.preferences.JavadocConfigurationPropertyPage$1.run(JavadocConfigurationPropertyPage.java:210) at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:113) Root exception: java.lang.NullPointerException at org.eclipse.jdt.internal.corext.javadoc.JavaDocLocations.setProjectJavadocLocation(JavaDocLocations.java:233) at org.eclipse.jdt.ui.JavaUI.setProjectJavadocLocation(JavaUI.java:770) at org.eclipse.jdt.internal.ui.preferences.JavadocConfigurationPropertyPage$1.run(JavadocConfigurationPropertyPage.java:210) at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:113)

Files changed in fix:
org.eclipse.jdt.ui/core extension/org/eclipse/jdt/internal/corext/javadoc/JavaDocLocations.java