Project: Birt
Bug 116379 Equals(object) method in class StringValue doesn't process the condition when value is null.
Reported: 2005-11-15 01:24:53 | Status: closed fixed

Description: Equals(object) method in class StringValue doesn't process the condition when value is null. Steps to reproduce: 1. Run attached file number_format.xml through ReportRunner Expected result: No Exception Actual result: SEVERE: An error happened while running the report. Cause: java.lang.NullPointerException at org.eclipse.birt.report.engine.css.engine.value.StringValue.equals (StringValue.java:68) at org.eclipse.birt.report.engine.css.dom.StyleDeclaration.equals (StyleDeclaration.java:94) at org.eclipse.birt.report.engine.parser.EngineIRVisitor.assignStyleName (EngineIRVisitor.java:1418) at org.eclipse.birt.report.engine.parser.EngineIRVisitor.setupStyledElement (EngineIRVisitor.java:869) at org.eclipse.birt.report.engine.parser.EngineIRVisitor.setupReportItem (EngineIRVisitor.java:1084) at org.eclipse.birt.report.engine.parser.EngineIRVisitor.visitDataItem (EngineIRVisitor.java:641) at org.eclipse.birt.report.model.api.DesignVisitor$Forwarder.visitDataItem (DesignVisitor.java:680) at org.eclipse.birt.report.model.elements.DataItem.apply (DataItem.java:59) at org.eclipse.birt.report.model.api.DesignVisitor.apply (DesignVisitor.java:90) at org.eclipse.birt.report.engine.parser.EngineIRVisitor.visitCell (EngineIRVisitor.java:883) at org.eclipse.birt.report.model.api.DesignVisitor$Forwarder.visitCell (DesignVisitor.java:764) at org.eclipse.birt.report.model.elements.Cell.apply(Cell.java:92) at org.eclipse.birt.report.model.api.DesignVisitor.apply (DesignVisitor.java:90) at org.eclipse.birt.report.engine.parser.EngineIRVisitor.visitRow (EngineIRVisitor.java:845) at org.eclipse.birt.report.model.api.DesignVisitor$Forwarder.visitRow (DesignVisitor.java:788) at org.eclipse.birt.report.model.elements.TableRow.apply (TableRow.java:93) at org.eclipse.birt.report.model.api.DesignVisitor.apply (DesignVisitor.java:90) at org.eclipse.birt.report.engine.parser.EngineIRVisitor.visitGrid (EngineIRVisitor.java:688) at org.eclipse.birt.report.model.api.DesignVisitor$Forwarder.visitGrid (DesignVisitor.java:800) at org.eclipse.birt.report.model.elements.GridItem.apply (GridItem.java:139) at org.eclipse.birt.report.model.api.DesignVisitor.apply (DesignVisitor.java:90) at org.eclipse.birt.report.engine.parser.EngineIRVisitor.visitReportDesign (EngineIRVisitor.java:275) at org.eclipse.birt.report.model.api.DesignVisitor$Forwarder.visitReportDesign (DesignVisitor.java:862) at org.eclipse.birt.report.model.elements.ReportDesign.apply (ReportDesign.java:76) at org.eclipse.birt.report.model.api.DesignVisitor.apply (DesignVisitor.java:90) at org.eclipse.birt.report.engine.parser.EngineIRVisitor.translate (EngineIRVisitor.java:213) at org.eclipse.birt.report.engine.parser.ReportParser.parse (ReportParser.java:111) at org.eclipse.birt.report.engine.api.impl.RunAndRenderTask.run (RunAndRenderTask.java:150) at org.eclipse.birt.report.engine.api.ReportRunner.executeReport (ReportRunner.java:178) at org.eclipse.birt.report.engine.api.ReportRunner.execute (ReportRunner.java:115) at org.eclipse.birt.report.engine.api.ReportRunner.main (ReportRunner.java:86) Picked up _JAVA_OPTIONS: -Dawt.toolkit=mercury.awt.awtSW -Xrunmicsupp - Xbootclasspath/a:C:\PROGRA~1\COMMON~1\MERCUR~1\SHARED~1\JAVAAD~1 \classes;C:\PROGRA~1\COMMON~1\MERCUR~1\SHARED~1\JAVAAD~1\classes\mic.jar

Files changed in fix:
engine/org.eclipse.birt.report.engine/src/org/eclipse/birt/report/engine/css/engine/value/StringValue.java