Re: [xml] FW: SAXHandler is not reset
- From: Daniel Veillard <veillard redhat com>
- To: Alexei Snisarenko <alexei snisarenko gmail com>
- Cc: xml gnome org
- Subject: Re: [xml] FW: SAXHandler is not reset
- Date: Fri, 6 May 2005 06:05:13 -0400
On Fri, May 06, 2005 at 01:24:10PM +0400, Alexei Snisarenko wrote:
Here is complete cutnpaste of my example. It can be compiled and run.
So it's my job to remove all the XPath stuff which is obviously
unrelated to the problem based on your description ?
Anyway I compiled it, lots of warnings the code doesn't look clean at all:
paphio:~/XML -> g++ -g -O -pedantic -W -Wformat -Wunused -Wimplicit -Wreturn-type -Wswitch -Wcomment
-Wtrigraphs -Wformat -Wchar-subscripts -Wuninitialized -Wparentheses -Wshadow -Wpointer-arith -Wcast-align
-Wwrite-strings -Waggregate-return -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Winline
-Wredundant-decls -Wall -Iinclude -o tst tst.c .libs/libxml2.a -lpthread -lm -lz
tst.c:14: warning: unused parameter 'Ctx'
tst.c:14: warning: unused parameter 'Name'
tst.c:14: warning: unused parameter 'Atts'
tst.c:45: warning: missing initializer for member `_xmlSAXHandler::externalSubset'
tst.c:45: warning: missing initializer for member `_xmlSAXHandler::initialized'
tst.c:45: warning: missing initializer for member `_xmlSAXHandler::_private'
tst.c:45: warning: missing initializer for member `_xmlSAXHandler::startElementNs'
tst.c:45: warning: missing initializer for member `_xmlSAXHandler::endElementNs'tst.c:45: warning: missing
initializer for member `_xmlSAXHandler::serror'
paphio:~/XML ->
Then ran it on a local test:
paphio:~/XML -> ./tst tst.xml /
DEBUG OUTPUT SHOULD NOT OCCUR AFTER THIS LINE!!! 118
Text to parse:
<?xml version="1.0"?>
<!DOCTYPE script SYSTEM "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<script type="text/javascript"><![CDATA[
document.write("hullo");
]]></script>
Result (1 nodes):
= node "(null)": type 9
paphio:~/XML ->
I don't see any "XXX DEBUG is called" output !
I don't know what is broken on your side, but maybe you miscompiled it
or something... I can't reproduce your problem.
Please trim down your example to just the problem seen, make sure you compiled
correctly and against the right headers and libraries, and only if you can
reproduce the problem after making sure all is correct then repost clean code,
how you compiled it, the library version used, and then I will try to reproduce
the problem again.
Daniel
--
Daniel Veillard | Red Hat Desktop team http://redhat.com/
veillard redhat com | libxml GNOME XML XSLT toolkit http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]