After I upgraded to the latest CVS version of XalanJ yesterday or the
day before, I've had the following very strange problem. I'm finding
it very difficult to track down, so I'm posting this partial
description in the hopes that someone else will be able to provide
better intuition.
The bug manifests itself in the following error message:
[Fatal Error] :-1:-1: Attribute "rewritePrefix" bound to namespace ""
was already specified for element "rewriteURI".
The lack of line numbers may not be significant, I think they used to
be there before I did a little shotgun debugging in frustration.
The document is perfectly valid and does not have duplicate attributes.
Fairly deep in my code, I find:
if (parserFactory != null) {
SAXParser parser = parserFactory.newSAXParser();
System.out.println("FIXME: parser=" + parser);
// This prints:
// FIXME: [EMAIL PROTECTED]
XMLReader reader = parser.getXMLReader();
reader.setContentHandler(new TestFilter());
reader.parse(new InputSource(is));
// Things go bang here.
Now, the really odd thing (IMHO) is that if I do not set a content
handler, the problem does not appear. And the TestFilter() content
handler is just a wrapper around XMLFilterImpl. It started with a
single method that printed the start tag (this error occurs on the
second element in the document), but I even tried renaming that to
something not in the SAX API. It still goes bang.
Hints or suggestions most appreciated.
Be seeing you,
norm
--
[EMAIL PROTECTED] | The truest wild beasts live in the most
XML Standards Engineer | populous places.--Graci\'an
XML Technology Center |
Sun Microsystems, Inc. |
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]