Lewis,

I can't comment on what the behavior is supposed to be, but I tried reproducing the same xmlns error in my test XSL, and Xalan (I am using 2.7.1) did not hang, it quit with an appropriate error message.

I believe if the input XSL is no good, Xalan will then try to find an XSL to use via a "xml-stylesheet" processing-instruction in the input XML file. My test XML file did not have this instruction, so for my test Xalan also reports this and then quits. But I see your output does not mention not being able to find a xml-stylesheet PI. Could it be your "file.xhtml" has a xml-stylesheet PI and then Xalan is running and/or hanging on that?

Good luck,
Nathan

McGibbney, Lewis John wrote:
Hi list,

I'm not sure what the bahaviour is meant to be here, I'm also not sure if there 
is a Jira issue files for this one so I thought the best thing to do would be 
to report here.

Basically when running o.a.x.xslt.Process -IN file.xhtml -XSL file.xsl -OUT 
file.xml Xalan-j hangs rather than skipping out of the class. For clarity I've 
attached the dodgy snippet from xsl I was using when the behaviour occured, as 
well as the terminal output before I skipped out.

<xsl:stylesheet version="1.0"
        xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
        
xmlns:ukm="http://www.legislation.gov.uk/schema/schemaLegislationMetadata.xsd";
        xmlns:uk>
  <xsl:output method="xml" version="1.0" omit-xml-declaration="no" 
indent="yes"/>
  <xsl:param name="versionParam" select="'1.0'"/>

much much more xsl code.

lewis@lewis-01:~/yax$ ./testRun.sh
[Fatal Error] stripMarkup.xsl:25:10: Attribute name "xmlns:uk" associated with an element 
type "xsl:stylesheet" must be followed by the ' = ' character.
file:///home/lewis/yax/examples/xslt/stripMarkup.xsl; Line #25; Column #10; 
org.xml.sax.SAXParseException; systemId: file:///home/lewis/yax/examples/xslt/stripMarkup.xsl; 
lineNumber: 25; columnNumber: 10; Attribute name "xmlns:uk" associated with an element 
type "xsl:stylesheet" must be followed by the ' = ' character.

exit
^Z
[1]+  Stopped                 ./testRun.sh

Thanks, if this is an issue please say so and I will log a Jira accordingly.


Lewis

Glasgow Caledonian University is a registered Scottish charity, number SC021474

Winner: Times Higher Education’s Widening Participation Initiative of the Year 
2009 and Herald Society’s Education Initiative of the Year 2009.
http://www.gcu.ac.uk/newsevents/news/bycategory/theuniversity/1/name,6219,en.html

Winner: Times Higher Education’s Outstanding Support for Early Career 
Researchers of the Year 2010, GCU as a lead with Universities Scotland partners.
http://www.gcu.ac.uk/newsevents/news/bycategory/theuniversity/1/name,15691,en.html

--
Nathan Nadeau
n...@gleim.com
Software Development
Gleim Publications, Inc.
http://www.gleim.com

Reply via email to