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 220699 - NullPointerException at org.netbeans.modules.form.JavaCodeGenerator.getEventHandlerSection
Summary: NullPointerException at org.netbeans.modules.form.JavaCodeGenerator.getEventH...
Status: RESOLVED FIXED
Alias: None
Product: guibuilder
Classification: Unclassified
Component: Code (show other bugs)
Version: 7.3
Hardware: All All
: P3 normal (vote)
Assignee: issues@guibuilder
URL:
Keywords:
: 255920 (view as bug list)
Depends on:
Blocks:
 
Reported: 2012-10-24 00:13 UTC by Chiana
Modified: 2015-10-15 01:23 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 193976


Attachments
stacktrace (1.76 KB, text/plain)
2012-10-24 00:13 UTC, Chiana
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Chiana 2012-10-24 00:13:00 UTC
Build: NetBeans IDE Dev (Build 201210231040)
VM: Java HotSpot(TM) 64-Bit Server VM, 23.5-b02, Java(TM) SE Runtime Environment, 1.7.0_09-b05
OS: Linux

User Comments:
Chiana: Right-clicked on a button and selected action->actionperformed

Chiana: Double clicked on a newly inserted button in a newly created JDialog form.




Stacktrace: 
java.lang.NullPointerException
   at org.netbeans.modules.form.JavaCodeGenerator.getEventHandlerSection(JavaCodeGenerator.java:3331)
   at org.netbeans.modules.form.JavaCodeGenerator.getEventHandlerText(JavaCodeGenerator.java:3316)
   at org.netbeans.modules.form.JavaCodeGenerator$FormListener.formChanged(JavaCodeGenerator.java:3960)
   at org.netbeans.modules.form.FormModel.fireEvents(FormModel.java:1322)
   at org.netbeans.modules.form.FormModel.fireEventBatch(FormModel.java:1295)
   at org.netbeans.modules.form.FormModel.firePendingEvents(FormModel.java:1258)
Comment 1 Chiana 2012-10-24 00:13:01 UTC
Created attachment 126420 [details]
stacktrace
Comment 2 Tomas Pavek 2012-11-07 13:29:34 UTC
The exception indicates some setup problem, there is no GuardedSectionManager. In the log I can see a strange exception java.lang.IllegalArgumentException: No parser for mime type: text/x-java.
Looks like if the installation was seriously broken.

I've made a fix that better handles the missing guarded support so it does not throw an exception.
http://hg.netbeans.org/jet-main/rev/315759324669
Comment 3 Quality Engineering 2012-11-08 02:50:04 UTC
Integrated into 'main-golden', will be available in build *201211080001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/315759324669
User: Tomas Pavek <tpavek@netbeans.org>
Log: #220699: better check for guarded sections availability
Comment 4 Tomas Pavek 2015-10-14 13:28:27 UTC
*** Bug 255920 has been marked as a duplicate of this bug. ***
Comment 5 Quality Engineering 2015-10-15 01:23:02 UTC
Integrated into 'main-silver', will be available in build *201510150002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/0c426f97d32f
User: Tomas Pavek <tpavek@netbeans.org>
Log: #255920: better check to avoid NPE on missing guarded code support (tried in #220699)