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 90500 - Odd NPE after commit
Summary: Odd NPE after commit
Status: REOPENED
Alias: None
Product: versioncontrol
Classification: Unclassified
Component: CVS (show other bugs)
Version: 6.x
Hardware: All All
: P4 blocker (vote)
Assignee: issues@versioncontrol
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-12-03 23:58 UTC by _ tboudreau
Modified: 2009-12-21 14:56 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description _ tboudreau 2006-12-03 23:58:48 UTC
A few seconds after committing some changes, I got the following:

java.lang.NullPointerException
	at sun.font.TrueTypeFont.readBlock(TrueTypeFont.java:304)
	at sun.font.TrueTypeFont.readBlock(TrueTypeFont.java:323)
	at sun.font.FileFont.getGlyphImage(Native Method)
	at sun.font.FileFontStrike.getGlyphImagePtr(FileFontStrike.java:270)
	at sun.font.FileFontStrike.getGlyphAdvance(FileFontStrike.java:476)
	at sun.font.FileFontStrike.getCodePointAdvance(FileFontStrike.java:496)
	at sun.font.FontDesignMetrics.handleCharWidth(FontDesignMetrics.java:402)
	at sun.font.FontDesignMetrics.getLatinCharWidth(FontDesignMetrics.java:411)
	at sun.font.FontDesignMetrics.charsWidth(FontDesignMetrics.java:497)
	at javax.swing.text.Utilities.getTabbedTextWidth(Utilities.java:256)
	at javax.swing.text.Utilities.getTabbedTextWidth(Utilities.java:191)
	at javax.swing.text.PlainView.getLineWidth(PlainView.java:643)
	at javax.swing.text.PlainView.calculateLongestLine(PlainView.java:620)
	at javax.swing.text.PlainView.updateMetrics(PlainView.java:192)
	at javax.swing.text.PlainView.updateDamage(PlainView.java:501)
	at javax.swing.text.PlainView.insertUpdate(PlainView.java:425)
	at javax.swing.plaf.basic.BasicTextUI$RootView.insertUpdate(BasicTextUI.java:1589)
	at
javax.swing.plaf.basic.BasicTextUI$UpdateHandler.insertUpdate(BasicTextUI.java:1848)
	at javax.swing.text.AbstractDocument.fireInsertUpdate(AbstractDocument.java:185)
	at javax.swing.text.AbstractDocument.handleInsertString(AbstractDocument.java:734)
	at javax.swing.text.AbstractDocument.insertString(AbstractDocument.java:693)
	at javax.swing.text.PlainDocument.insertString(PlainDocument.java:114)
	at javax.swing.text.AbstractDocument.replace(AbstractDocument.java:655)
	at javax.swing.text.JTextComponent.setText(JTextComponent.java:1693)
	at
org.netbeans.modules.versioning.system.cvss.CommandReport.createCenterComponent(CommandReport.java:63)
	at
org.netbeans.modules.versioning.system.cvss.CommandReport.<init>(CommandReport.java:47)
	at
org.netbeans.modules.versioning.system.cvss.ExecutorSupport.report(ExecutorSupport.java:437)
	at
org.netbeans.modules.versioning.system.cvss.ExecutorSupport.commandTerminated(ExecutorSupport.java:398)
	at
org.netbeans.modules.versioning.system.cvss.ClientRuntime$1.taskFinished(ClientRuntime.java:143)
	at org.openide.util.Task.notifyFinished(Task.java:205)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:547)
[catch] at
org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:963)
Comment 1 Maros Sandor 2007-01-05 10:13:54 UTC
I guess this is a random issue, most probably a JDK's one.
Comment 2 _ tboudreau 2007-01-06 05:33:41 UTC
Maybe trying writing it under the document's write lock?
Comment 3 Maros Sandor 2007-09-26 10:49:59 UTC
It happened log time ago, please reopen if it happens again along with JDK and other system information so that I can
file a JDK bug then.
Comment 4 _ tboudreau 2007-09-27 00:21:46 UTC
The problem looks pretty obvious from the stack trace - also why it is hard to reproduce.  Swing components are being created on a thread other than the 
AWT Event Thread.  That is never safe, and will occasionally fail in strange ways.

Just replan org.netbeans.modules.versioning.system.cvss.ExecutorSupport.report() to the event thread with EventQueue.invokeLater(), and you can mark this 
issue fixed. 
Comment 5 Quality Engineering 2009-12-21 05:36:57 UTC
This bug was reported against NetBeans IDE 6.0 or an older release, or against a non-maintained module. NetBeans team does not have enough resources to get to this issue, therefore we are closing the issue as a WONTFIX. If you are interested in providing a patch for this bug, please see our NetFIX guidelines for how to proceed. 

We apologize for any inconvenience.


Thank you.
The NetBeans Team
Comment 6 _ tboudreau 2009-12-21 14:56:27 UTC
Reverting bogus issue closure.  Easy to test if components are still being created on the wrong thread and either fix or verify already fixed.