xerces-c-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bovy, Stephen J" <STEPHEN.B...@ca.com>
Subject RE: Wrapper4InputSource IBM parse gets S01, help !!!!
Date Fri, 23 Apr 2004 17:34:59 GMT
Thanks, I have got it working , it was the delete's that caused the
problem.

All I had to do was change the following:

>>>>>domBufIS = new Wrapper4InputSource ( memBufIS, false
);<<<<<<<<<<<<< 

then the parse:

doc = parser->parse(*domBufIS);

and then the delete's

delete domBufIS;
delete memBufIS;
 

-----Original Message-----
From: Gareth Reakes [mailto:gareth@parthenoncomputing.com] 
Sent: Friday, April 23, 2004 2:31 AM
To: xerces-c-dev@xml.apache.org
Subject: Re: Wrapper4InputSource IBM parse gets S01, help !!!!

Hi,
	have you initialized xerces? There is a sample that does what
you are trying to do here (MemParse). Worth taking a look there.


Gareth


On Thu, 22 Apr 2004, Bovy, Stephen J wrote:

> I have the following code which I am using with
>
> the IBM toolkit 1.6 which is xerces 2.2
>
> MemBufInputSource* memBufIS = NULL;
> Wrapper4InputSource* domBufIS = NULL;
>
> memBufIS = new MemBufInputSource
> (
>     (const XMLByte*) sfile.ipc->pbuff
>     , sfile.ipc->leng
>     , gMemBufId
>     , false
> );
>
> fprintf ( stderr, "MemBufInput created\n");
>
> domBufIS = new Wrapper4InputSource ( memBufIS );
>
> fprintf ( stderr, "DomBufInput created\n");
>
> static const XMLCh gLS   = { chLatin_L, chLatin_S, chNull };
>
> impl = DOMImplementationRegistry::getDOMImplementation(gLS);
>
> parser =
>   ((DOMImplementationLS*)impl)->
>   createDOMBuilder ( DOMImplementationLS::MODE_SYNCHRONOUS, 0 );
>
> fprintf ( stderr, "Begin Parse\n");
>
> doc = parser->parse(*domBufIS);
>
> I am getting a S01 when the parser is invoked, any suggestions would 
> be appreciated !!
>
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-c-dev-help@xml.apache.org
>

-- 
Gareth Reakes, Managing Director      Parthenon Computing
+44-1865-811184                  http://www.parthcomp.com

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



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


Mime
View raw message