Mantis - Resin
Viewing Issue Advanced Details
1704 major always 04-24-07 05:31 05-15-07 15:35
hgschmie  
ferg  
normal  
closed 3.1.0  
fixed  
none    
none 3.1.2  
0001704: Resin XML parser does not like empty name spaces
According to http://java.sun.com/j2se/1.5.0/docs/api/org/w3c/dom/Element.html#setAttributeNS(java.lang.String,%20java.lang.String,%20java.lang.String), [^] an element wanting to set an attribute without a namespace is required to set this namespace to null. However, in doing so, both Resin 3.1.0 and 3.0.23 might throw NullPointerExceptions, because they then subsequently set the localName to null (Resin 3.0.23 in QName.java, line 128, Resin 3.1.0 in QName.java, line 59). A subsequent call to getAttributeNS will then throw an NPE in QAttributedNode, line 146 (Resin 3.1.0).
This particular sequence is e.g. used by Apache Batik 1.7beta1 when generating Style objects (org.apache.batik.svggen.DefaultStyleHandler#setStyle(Element, Map, SVGGeneratorContext)) and leads to an reproducible NPE when running with Resin and works well when explicitly forcing the JDK default implementation.

This is a bug in Resin and should be fixed.

Notes
(0001924)
ferg   
05-15-07 15:35   
xml/017i