This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 172422 - [68cat] NPE from NbKeymap.getContext
Summary: [68cat] NPE from NbKeymap.getContext
Status: VERIFIED FIXED
Alias: None
Product: platform
Classification: Unclassified
Component: Window System (show other bugs)
Version: 6.x
Hardware: PC Windows Vista
: P2 blocker (vote)
Assignee: Jesse Glick
URL:
Keywords:
Depends on:
Blocks: 152576
  Show dependency tree
 
Reported: 2009-09-16 21:28 UTC by peter_rogge
Modified: 2009-09-20 00:29 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
simple modulesuite to recreate the exception (585.56 KB, text/plain)
2009-09-17 12:24 UTC, peter_rogge
Details

Note You need to log in before you can comment on or make changes to this bug.
Description peter_rogge 2009-09-16 21:28:59 UTC
Hi,
nothings goes more :-(.

Run rcp-project.
Create node in BeanTreeView.

Press Enter to avoke DefaultAction from node -> NPE.
Tip in NotifyDescriptor.InputLine -> NPE.
Tip in TopComponent -> JTextField -> NPE.

Try to copy in the exception-dialog -> nothing happens (dialog resize to default size).
Try project in 6.7.1 -> runs fine :-).


Here the exception:
java.lang.NullPointerException
        at org.netbeans.core.NbKeymap.getContext(NbKeymap.java:238)
        at
org.netbeans.core.windows.ShortcutAndMenuKeyEventProcessor.dispatchKeyEvent(ShortcutAndMenuKeyEventProcessor.java:193)
        at java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(DefaultKeyboardFocusManager.java:962)
        at java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(DefaultKeyboardFocusManager.java:841)
        at java.awt.DefaultKeyboardFocusManager.dispatchEvent(DefaultKeyboardFocusManager.java:668)
        at java.awt.Component.dispatchEventImpl(Component.java:4502)
        at java.awt.Container.dispatchEventImpl(Container.java:2099)
        at java.awt.Window.dispatchEventImpl(Window.java:2475)
        at java.awt.Component.dispatchEvent(Component.java:4460)
        at java.awt.EventQueue.dispatchEvent(EventQueue.java:599)
        at org.netbeans.core.TimableEventQueue.dispatchEvent(TimableEventQueue.java:117)
[catch] 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)

Product Version: NetBeans IDE Build 200909151512
Java: 1.6.0_16; Java HotSpot(TM) Server VM 14.2-b01
System: Windows Vista version 6.0 running on x86; Cp1252; de_DE

See also:
http://www.nabble.com/-68cat---editor--NullPointerException---NbKeymap---Focussystem-td25479697.html
Comment 1 Max Sauer 2009-09-16 21:39:39 UTC
Reassigning, please evaluate.
Comment 2 Jiri Kovalsky 2009-09-16 21:40:29 UTC
Reported by NetCAT 6.8 participant hence adding [68cat] prefix.
Comment 3 peter_rogge 2009-09-17 07:13:11 UTC
The same under:

Operating System = Windows XP version 5.1 running on x86
Java; VM; Vendor = 1.6.0_07; Java HotSpot(TM) Server VM 10.0-b23; Sun Microsystems Inc.
Runtime          = Java(TM) SE Runtime Environment 1.6.0_07-b06
Comment 4 Stanislav Aubrecht 2009-09-17 09:15:18 UTC
the line throwing NPE was introduced in the fix for issue #152576, reassigning
Comment 5 peter_rogge 2009-09-17 12:24:17 UTC
Created attachment 87848 [details]
simple modulesuite to recreate the exception
Comment 6 peter_rogge 2009-09-17 12:26:37 UTC
Sorry,
this attachment should be to 172421.
Comment 7 Jesse Glick 2009-09-17 15:27:14 UTC
No clear information to reproduce (would want a demo suite). From the stack trace it seems like no NbKeymap has been
created, whereas this should always happen during startup AFAIK. Can easily make this exception impossible but curious
how it happened to begin with. core-main #d9df58e77cae
Comment 8 Quality Engineering 2009-09-18 22:49:51 UTC
Integrated into 'main-golden', will be available in build *200909181401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/d9df58e77cae
User: Jesse Glick <jglick@netbeans.org>
Log: #172422: unreproducible NPE. Making sure context is never null.
Comment 9 peter_rogge 2009-09-19 09:58:21 UTC
Under

Product Version = NetBeans IDE Dev (Build 200909181401) (#e14c9c33faed)
Operating System = Windows Vista version 6.0 running on x86
Java; VM; Vendor = 1.6.0_16; Java HotSpot(TM) Client VM 14.2-b01; Sun Microsystems Inc.
Runtime = Java(TM) SE Runtime Environment 1.6.0_16-b01

it seems, that the bug is fixed :-).
Comment 10 Jesse Glick 2009-09-20 00:29:24 UTC
OK, thanks for info. Still curious what the original problem was.