Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 322293 - NPE when select Hyperlink from MultipleHyperlinkPresenter List
Summary: NPE when select Hyperlink from MultipleHyperlinkPresenter List
Status: VERIFIED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 3.6   Edit
Hardware: PC Mac OS X
: P3 normal (vote)
Target Milestone: 3.7 M5   Edit
Assignee: Scott Kovatch CLA
QA Contact: Silenio Quarti CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 199283
  Show dependency tree
 
Reported: 2010-08-10 17:11 EDT by Frank Becker CLA
Modified: 2011-01-25 16:28 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Frank Becker CLA 2010-08-10 17:11:07 EDT
Here the Stack Trace from macosx-cocoa-x86_64 

java.lang.NullPointerException
	at org.eclipse.swt.widgets.Shell.setWindowVisible(Shell.java:1782)
	at org.eclipse.swt.widgets.Shell.setVisible(Shell.java:1704)
	at org.eclipse.jface.text.AbstractInformationControl.setVisible(AbstractInformationControl.java:506)
	at org.eclipse.jface.text.AbstractInformationControlManager.hideInformationControl(AbstractInformationControlManager.java:1231)
	at org.eclipse.jface.text.hyperlink.MultipleHyperlinkPresenter$MultipleHyperlinkHoverManager.hideInformationControl(MultipleHyperlinkPresenter.java:628)
	at org.eclipse.jface.text.hyperlink.MultipleHyperlinkPresenter$LinkListInformationControl.openSelectedLink(MultipleHyperlinkPresenter.java:323)
	at org.eclipse.jface.text.hyperlink.MultipleHyperlinkPresenter$LinkListInformationControl.access$1(MultipleHyperlinkPresenter.java:317)
	at org.eclipse.jface.text.hyperlink.MultipleHyperlinkPresenter$3.widgetSelected(MultipleHyperlinkPresenter.java:278)
	at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:234)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
	at org.eclipse.swt.widgets.Display.sendEvent(Display.java:3776)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1367)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1390)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1375)
	at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:1187)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3622)
	at org.eclipse.swt.widgets.Display.applicationNextEventMatchingMask(Display.java:4479)
	at org.eclipse.swt.widgets.Display.applicationProc(Display.java:4739)
	at org.eclipse.swt.internal.cocoa.OS.objc_msgSendSuper(Native Method)
	at org.eclipse.swt.widgets.Widget.callSuper(Widget.java:220)
	at org.eclipse.swt.widgets.Widget.mouseDownSuper(Widget.java:1025)
	at org.eclipse.swt.widgets.Table.mouseDownSuper(Table.java:1930)
	at org.eclipse.swt.widgets.Widget.mouseDown(Widget.java:1021)
	at org.eclipse.swt.widgets.Control.mouseDown(Control.java:2240)
	at org.eclipse.swt.widgets.Table.mouseDown(Table.java:1912)
	at org.eclipse.swt.widgets.Display.windowProc(Display.java:4976)
	at org.eclipse.swt.internal.cocoa.OS.objc_msgSendSuper(Native Method)
	at org.eclipse.swt.widgets.Widget.callSuper(Widget.java:220)
	at org.eclipse.swt.widgets.Widget.windowSendEvent(Widget.java:1943)
	at org.eclipse.swt.widgets.Shell.windowSendEvent(Shell.java:2008)
	at org.eclipse.swt.widgets.Display.windowProc(Display.java:5040)
	at org.eclipse.swt.internal.cocoa.OS.objc_msgSendSuper(Native Method)
	at org.eclipse.swt.widgets.Display.applicationSendEvent(Display.java:4582)
	at org.eclipse.swt.widgets.Display.applicationProc(Display.java:4659)
	at org.eclipse.swt.internal.cocoa.OS.objc_msgSend(Native Method)
	at org.eclipse.swt.internal.cocoa.NSApplication.sendEvent(NSApplication.java:115)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3274)
	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2629)
	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2593)
	at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2427)
	at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:670)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:663)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
	at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:115)
	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:369)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
	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:597)
	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:619)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:574)
	at org.eclipse.equinox.launcher.Main.run(Main.java:1407)
	at org.eclipse.equinox.launcher.Main.main(Main.java:1383)
Comment 1 Scott Kovatch CLA 2010-08-18 13:48:10 EDT
Do you have an example of where this happens? Any steps to reproduce?
Comment 2 Frank Becker CLA 2010-08-19 17:22:29 EDT
(In reply to comment #1)
> Do you have an example of where this happens? Any steps to reproduce?

Yes please see attachment https://bugs.eclipse.org/bugs/attachment.cgi?id=176402 of https://bugs.eclipse.org/bugs/show_bug.cgi?id=199283
Comment 3 Scott Kovatch CLA 2011-01-18 13:38:55 EST
Requested a new mylyn that shows the bug happening. The stack trace is out of date compared to HEAD of Cocoa SWT.
Comment 4 Frank Becker CLA 2011-01-19 14:22:19 EST
Here the Stack Trace from Eclipse 3.7.0 I20101208-1300 (3.7M4)
java.lang.NullPointerException
	at org.eclipse.swt.widgets.Shell.setWindowVisible(Shell.java:1933)
	at org.eclipse.swt.widgets.Shell.setVisible(Shell.java:1855)
	at org.eclipse.jface.text.AbstractInformationControl.setVisible(AbstractInformationControl.java:505)
	at org.eclipse.jface.text.AbstractInformationControlManager.hideInformationControl(AbstractInformationControlManager.java:1242)
	at org.eclipse.jface.text.hyperlink.MultipleHyperlinkPresenter$MultipleHyperlinkHoverManager.hideInformationControl(MultipleHyperlinkPresenter.java:672)
	at org.eclipse.jface.text.hyperlink.MultipleHyperlinkPresenter$LinkListInformationControl.openSelectedLink(MultipleHyperlinkPresenter.java:365)
	at org.eclipse.jface.text.hyperlink.MultipleHyperlinkPresenter$LinkListInformationControl.access$1(MultipleHyperlinkPresenter.java:359)
	at org.eclipse.jface.text.hyperlink.MultipleHyperlinkPresenter$4.mouseUp(MultipleHyperlinkPresenter.java:335)
	at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:213)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
	at org.eclipse.swt.widgets.Display.sendEvent(Display.java:3955)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1435)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1458)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1443)
	at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:1255)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3801)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3454)
	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2640)
	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2604)
	at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2438)
	at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:671)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:664)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
	at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:115)
	at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:369)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
	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:597)
	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:577)
	at org.eclipse.equinox.launcher.Main.run(Main.java:1410)
	at org.eclipse.equinox.launcher.Main.main(Main.java:1386)
Comment 5 Scott Kovatch CLA 2011-01-19 14:49:04 EST
(In reply to comment #4)
> Here the Stack Trace from Eclipse 3.7.0 I20101208-1300 (3.7M4)
> java.lang.NullPointerException
>     at org.eclipse.swt.widgets.Shell.setWindowVisible(Shell.java:1933)
>     at org.eclipse.swt.widgets.Shell.setVisible(Shell.java:1855)
>     at

Thanks, this is helpful. The only way this can happen is if the shell was disposed, so I'm checking in a fix that should take care of it. Reopen it if you still hit this, but It's now in HEAD > 20110119.
Comment 6 Frank Becker CLA 2011-01-20 15:33:29 EST
I verified this with 3.7 N20110119-2000

Thanks!!!