Re: [xml] SAX2 / empty namespace issue
- From: Daniel Veillard <veillard redhat com>
- To: Michael Day <mikeday yeslogic com>
- Cc: xml gnome org
- Subject: Re: [xml] SAX2 / empty namespace issue
- Date: Wed, 15 Jun 2005 08:17:07 -0400
On Wed, Jun 15, 2005 at 09:35:05PM +1000, Michael Day wrote:
Hi Daniel,
yes, please. If it can't be reproduced with the existing test tools
please provide a standalone C program, and the instance. We have the
instance so that is okay :-)
Here is a short C program that exhibits the problem:
/********************************************************/
#include <libxml/parser.h>
void func(void *foo, xmlErrorPtr err)
{
printf("error\n");
}
int main()
{
xmlDocPtr doc;
xmlSAXHandlerPtr sax = (xmlSAXHandlerPtr) &xmlDefaultSAXHandler;
xmlSetStructuredErrorFunc(&doc, func);
doc = xmlSAXParseFileWithData(sax, "dummy.xml", 0, NULL);
return 0;
}
/********************************************************/
When run on this instance document:
<foo xmlns:null=""/>
the structured error handler will never be called, and running it under
valgrind shows up some errors.
If no structured error handler is set then the correct namespace error
message is printed and valgrind says no errors.
Okay
The bug is that SAX2.c continues to call directly ctxt->sax->error and
ctxt->sax->warning instead of using the global __xmlRaiseError() framework.
This is a bug. Could you put it in bugzilla to make sure we don't loose
track of it ?
thanks !
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]