JDK-6800801 : NPE in JConsole when using Nimbus L&F
  • Type: Bug
  • Component: tools
  • Sub-Component: jconsole
  • Affected Version: 6u11
  • Priority: P5
  • Status: Resolved
  • Resolution: Fixed
  • OS: solaris_2.5.1
  • CPU: sparc
  • Submitted: 2009-02-03
  • Updated: 2013-09-05
  • Resolved: 2013-08-21
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 8
8 b106Fixed
Related Reports
Duplicate :  
Relates :  
Description
OPERATING SYSTEM(S):
Microsoft Windows XP [Version 5.1.2600]

FULL JDK VERSION(S):
java version "1.6.0_11"
Java(TM) SE Runtime Environment (build 1.6.0_11-b03)
Java HotSpot(TM) Client VM (build 11.0-b16, mixed mode)

DESCRIPTION:
Similar NPEs were fixed in 6u10 under CR 6612359.

Start JConsole from the commandline using the Nimbus look & feel:

jconsole -J-Dswing.defaultlaf=com.sun.java.swing.plaf.nimbus.NimbusLookAndFeel

The main window opens, but when creating the 'Connect to..' dialog, we get a NPE:

Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
	at sun.tools.jconsole.VMPanel.setUI(VMPanel.java:146)
	at javax.swing.JTabbedPane.updateUI(JTabbedPane.java:230)
	at javax.swing.JTabbedPane.<init>(JTabbedPane.java:189)
	at javax.swing.JTabbedPane.<init>(JTabbedPane.java:154)
	at sun.tools.jconsole.VMPanel.<init>(VMPanel.java:82)
	at sun.tools.jconsole.JConsole$4.run(JConsole.java:531)
	at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

Comments
Impact=Low, GUI is usable without Nimbus Likelihood=Low, people normally don' specify -J-Dswing.defaultlaf=com.sun.java.swing.plaf.nimbus.NimbusLookAndFeel Workaround=High, no known workaround exists, excapt not using Nimbus at all. LLH => P5
29-07-2013

WORK AROUND Don't use Nimbus.
03-02-2009