You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@xerces.apache.org by Erik Sloge <er...@eu.apbiotech.com> on 2001/04/02 11:25:55 UTC

Failure when starting SAX2 parser compiled in release mode for Win32

Hi,

I have created a COM component for Win32 using VC++ that incorporates the
Xerces-C XML parser v1.4.0 from 1/30 2001. The distributed binary DLL:s are
used. It runs perfectly all right when compiled in debug mode, but when
compiling the DLL in Release mode, the SAX2XMLReader object that is created
using the following line of code:

               SAX2XMLReader* parser = XMLReaderFactory::createXMLReader();

Throws an access voilation exception when calling:

               char* sXMLFile = ...... ;
               parser->parse(sXMLFile);

It does not call any of the implemented methods in the content handler
object that is derived from DefaultHandler before throwing the exception.
The supplied file name points to a valid XML file that opens all right with
the debug compiled version of the parser. I've had a look in the bug data
base and FAQ:s but have so far not managed to find anything describing any
solutions for this problem.

Any ideas?

Regards.

/Erik.


---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-c-dev-help@xml.apache.org


Re: Failure when starting SAX2 parser compiled in release mode for Win32

Posted by John Snelson <jp...@decisionsoft.com>.
Read the FAQ again. You are mixing runtime libraries.

John

Erik Sloge wrote:
> 
> Hi,
> 
> I have created a COM component for Win32 using VC++ that incorporates the
> Xerces-C XML parser v1.4.0 from 1/30 2001. The distributed binary DLL:s are
> used. It runs perfectly all right when compiled in debug mode, but when
> compiling the DLL in Release mode, the SAX2XMLReader object that is created
> using the following line of code:
> 
>                SAX2XMLReader* parser = XMLReaderFactory::createXMLReader();
> 
> Throws an access voilation exception when calling:
> 
>                char* sXMLFile = ...... ;
>                parser->parse(sXMLFile);
> 
> It does not call any of the implemented methods in the content handler
> object that is derived from DefaultHandler before throwing the exception.
> The supplied file name points to a valid XML file that opens all right with
> the debug compiled version of the parser. I've had a look in the bug data
> base and FAQ:s but have so far not managed to find anything describing any
> solutions for this problem.
> 
> Any ideas?
> 
> Regards.
> 
> /Erik.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-c-dev-help@xml.apache.org

-- 
John Snelson, Software Engineer       DecisionSoft Ltd.
Telephone: +44-1865-203192            http://www.decisionsoft.com

---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-c-dev-help@xml.apache.org