Page 1 of 1

Bug: Invalid XPath syntax in XSL:for-each hangs debugger

Posted: Thu Jul 01, 2004 4:06 pm
by Chris Maloney
Oxygen V4.1
Xalan 2.5.1

Using the following (invalid) code:
<xsl:for-each select="field[not(identity)">
<xsl:text>Output Something...</xsl:text>
</xsl:for-each>

Note missing ']' in XPath.

Generates a Stack Overflow and causes Oxygen to eat large quantities of memory until a out of memory error occurs.

Obviously, correcting the XPath statement resolves the problem but it shouldn't be causing a hang.

Posted: Thu Jul 01, 2004 5:01 pm
by george
Hi Chris,

I'm affraid we cannot control that, the SOE appears inside Xalan code when we try to create a Transformer object out of the stylesheet document. Anyway on my machine it does not fell like a hang, it takes some time to create the transformer then the error is reported in the Errors area and Oxygen remains usable. Saxon behaves better on this type of errors, if your stylesheet is not Xalan dependent you may consider using Saxon instead.

Best Regards,
George