Hello,

do you know if this is a bug or a feature ? If it is a bug, is it still a 
problem with the newer xerces versions?

Unfortunately we cann't use std::ifstream because of internal reasons. So it 
remains open if we decide to fix the xerces code or take newer versions.

Best regards,
 Borislav

-----Original Message-----
From: David Bertoni [mailto:[EMAIL PROTECTED]
Sent: Friday, October 21, 2005 6:51 PM
To: [email protected]
Subject: Re: Xalan-C++ 1.4 / Xerces C++ 2.1 Problem with paths
containing '#'


Borislav Stoyanov wrote:
> Hello there,
> 
> could be possible, that the above versions have problems with path names 
> containg a '#' character ?
> 
> For example
> 
> Y:\My#Path\MyFile.xsl
> 
> By trying opening it XalanTransformer.compileStylesheet(      
> pStylesheetSourceC,
>                                                               
> pCompiledStylesheetC);
> 
> throws an error.
> 

This should be more explicitly documented, but you have to provide
something that is either a valid URL, or can be converted to one by
prepending "file://". Since '#' is a special character in URLs, the 
parser thinks the part after the '#' is a fragment identifier.  Note 
that this is Xerces-C++ that's reporting this error, and Xalan-C++ has 
no control over the behavior.

> Is there any workaround?
> 

Yes.  Use a std::ifstream, instead of providing the file name, when you 
construct the InputSource for XalanTransformer::compileStylesheet().

Dave

Reply via email to