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 210007 - NullPointerException at javax.swing.text.JTextComponent.getCaretPosition
Summary: NullPointerException at javax.swing.text.JTextComponent.getCaretPosition
Status: RESOLVED FIXED
Alias: None
Product: editor
Classification: Unclassified
Component: Hints & Annotations (show other bugs)
Version: 7.2
Hardware: All All
: P3 normal (vote)
Assignee: Jan Lahoda
URL:
Keywords:
: 210469 (view as bug list)
Depends on:
Blocks:
 
Reported: 2012-03-23 14:17 UTC by gholmer
Modified: 2012-04-02 08:58 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 186194


Attachments
stacktrace (2.27 KB, text/plain)
2012-03-23 14:17 UTC, gholmer
Details

Note You need to log in before you can comment on or make changes to this bug.
Description gholmer 2012-03-23 14:17:36 UTC
Build: NetBeans IDE Dev (Build 201203230400)
VM: Java HotSpot(TM) Client VM, 22.0-b10, Java(TM) SE Runtime Environment, 1.7.0_02-b13
OS: Linux

User Comments:
gholmer: Closed four files at once (all that were open) in the editor.




Stacktrace: 
java.lang.NullPointerException
   at javax.swing.text.JTextComponent.getCaretPosition(JTextComponent.java:1693)
   at org.netbeans.modules.editor.hints.HintsUI.caretUpdate(HintsUI.java:948)
   at org.netbeans.modules.editor.hints.AnnotationHolder.setErrorDescriptionsImpl(AnnotationHolder.java:1056)
   at org.netbeans.modules.editor.hints.AnnotationHolder.access$1400(AnnotationHolder.java:121)
   at org.netbeans.modules.editor.hints.AnnotationHolder$6.run(AnnotationHolder.java:960)
   at org.netbeans.editor.BaseDocument.render(BaseDocument.java:1340)
Comment 1 gholmer 2012-03-23 14:17:41 UTC
Created attachment 117166 [details]
stacktrace
Comment 2 Jan Lahoda 2012-03-26 07:36:30 UTC
Fixed by:
http://hg.netbeans.org/main-silver/rev/2aa58a00e3c7

Thanks for the report.
Comment 3 Quality Engineering 2012-03-26 09:35:40 UTC
Integrated into 'main-golden', will be available in build *201203260401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/2aa58a00e3c7
User: Jan Lahoda <jlahoda@netbeans.org>
Log: #210007: ensure that Swing methods are only invoked from AWT, preventing NPE.
Comment 4 Jan Lahoda 2012-04-02 08:58:55 UTC
*** Bug 210469 has been marked as a duplicate of this bug. ***