NPE in Logging Infrastructure

Description

From

C:\Programs\PCGen\PCGen5179>"c:\Program Files (x86)\Java\jre6\bin\java.exe" -Dswing.aatext=true -Xms1024m -Xmx1024m -jar pcgen.jar
18:11:43.849 SEVERE AWT-EventQueue-1 ExportHandler:1978 Error replacing WEAPON.2.THDAMAGE
java.lang.NullPointerException
at pcgen.util.Logging.debugPrint(Logging.java:152)
at pcgen.core.term.BasePCTermEvaluator.convertToFloat(BasePCTermEvaluator.java:83)
at pcgen.core.term.BasePCTermEvaluator.resolve(BasePCTermEvaluator.java:64)
at pcgen.core.VariableProcessorEq.getInternalVariable(VariableProcessorEq.java:90)
at pcgen.core.VariableProcessor.lookupVariable(VariableProcessor.java:684)
at pcgen.core.VariableProcessor.processJepFormula(VariableProcessor.java:606)
at pcgen.core.VariableProcessor.getJepOnlyVariableValue(VariableProcessor.java:197)
at pcgen.core.VariableProcessor.getVariableValue(VariableProcessor.java:138)
at pcgen.core.Equipment.getVariableValue(Equipment.java:2182)
at pcgen.core.Equipment.getVariableValue(Equipment.java:2158)
at plugin.pretokens.test.PreVariableTester.passes(PreVariableTester.java:71)
at pcgen.core.prereq.PrereqHandler.passes(PrereqHandler.java:225)
at pcgen.core.prereq.PrereqHandler.passesAll(PrereqHandler.java:124)
at pcgen.core.character.WieldCategory.getSwitch(WieldCategory.java:208)
at pcgen.core.character.WieldCategory.adjustForSize(WieldCategory.java:197)
at pcgen.core.Equipment.getEffectiveWieldCategory(Equipment.java:5471)
at pcgen.core.Equipment.isWeaponOutsizedForPC(Equipment.java:5414)
at pcgen.io.exporttoken.WeaponToken.getDamage(WeaponToken.java:2422)
at pcgen.io.exporttoken.WeaponToken.getTHDamageToken(WeaponToken.java:1471)
at pcgen.io.exporttoken.WeaponToken.getWeaponToken(WeaponToken.java:472)
at pcgen.io.exporttoken.WeaponToken.getToken(WeaponToken.java:210)
at pcgen.io.ExportHandler.replaceToken(ExportHandler.java:1945)
at pcgen.io.ExportHandler.replaceLine(ExportHandler.java:1808)
at pcgen.io.ExportHandler.evaluateIIFChildren(ExportHandler.java:940)
at pcgen.io.ExportHandler.evaluateIIF(ExportHandler.java:854)
at pcgen.io.ExportHandler.evaluateIIFChildren(ExportHandler.java:918)
at pcgen.io.ExportHandler.evaluateIIF(ExportHandler.java:854)
at pcgen.io.ExportHandler.evaluateIIFChildren(ExportHandler.java:918)
at pcgen.io.ExportHandler.evaluateIIF(ExportHandler.java:854)
at pcgen.io.ExportHandler.processLoop(ExportHandler.java:1033)
at pcgen.io.ExportHandler.loopFOR(ExportHandler.java:970)
at pcgen.io.ExportHandler.processLoop(ExportHandler.java:1027)
at pcgen.io.ExportHandler.loopFOR(ExportHandler.java:970)
at pcgen.io.ExportHandler.write(ExportHandler.java:240)
at pcgen.gui.tabs.InfoCharacterSheet.updateCharacterInfo(InfoCharacterSheet.java:185)
at pcgen.gui.tabs.BaseCharacterInfoTab.forceRefresh(BaseCharacterInfoTab.java:70)
at pcgen.gui.tabs.BaseCharacterInfoTab.refresh(BaseCharacterInfoTab.java:158)
at pcgen.gui.CharacterInfo$tabChangeListener.stateChanged(CharacterInfo.java:482)
at javax.swing.JTabbedPane.fireStateChanged(Unknown Source)
at javax.swing.JTabbedPane$ModelListener.stateChanged(Unknown Source)
at javax.swing.DefaultSingleSelectionModel.fireStateChanged(Unknown Source)
at javax.swing.DefaultSingleSelectionModel.setSelectedIndex(Unknown Source)
at javax.swing.JTabbedPane.setSelectedIndexImpl(Unknown Source)
at javax.swing.JTabbedPane.setSelectedIndex(Unknown Source)
at javax.swing.plaf.basic.BasicTabbedPaneUI$Handler.mousePressed(Unknown Source)
at java.awt.Component.processMouseEvent(Unknown Source)
at javax.swing.JComponent.processMouseEvent(Unknown Source)
at java.awt.Component.processEvent(Unknown Source)
at java.awt.Container.processEvent(Unknown Source)
at java.awt.Component.dispatchEventImpl(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Window.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
at java.awt.EventQueue.access$000(Unknown Source)
at java.awt.EventQueue$1.run(Unknown Source)
at java.awt.EventQueue$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(Unknown Source)
at java.security.AccessControlContext$1.doIntersectionPrivilege(Unknown Source)
at java.awt.EventQueue$2.run(Unknown Source)
at java.awt.EventQueue$2.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at pcgen.gui.PCGen_Frame1$WaitCursorEventQueue.dispatchEvent(PCGen_Frame1.java:2933)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)

after exception Weapon Training is showing.

close and restart, load (2) *** no exception*** *** weapon training DOES NOT show***

it appears random whether I get the exception.
If I do NOT get the exception, I do NOT see Weapon Training with the rchetype;
if I get a Null Pointer Exception, then after tat resolves, the Weapon Training shows.

Environment

None

Activity

Show:
Andrew Maitland
January 4, 2012, 6:19 PM

NPE discovered by Data Bug

James Dempsey
January 4, 2012, 7:13 PM

This is caused by a Java logging race condition giving us a null logger. See http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=7016208

Fixed

Assignee

James Dempsey

Reporter

Andrew Maitland

Labels

None

Theme

None

Epic/Theme

None

Pending User Input

None

Time tracking

0m

Time remaining

0m

Components

Fix versions

Affects versions

Priority

Major
Configure