On Fri, Jul 21, 2006 at 02:37:33PM +0200, Ferry Huberts wrote: > Hi! > > I'm using the xmlReadfd function and I would like to route the parse errors > that > are reported on stderr into my application. > > How can I do this? > I have not been able to find the function to use, all I could find is the > function > xmlSetGenericErrorFunc but its description says that this will not work while > parsing!
Hum, try to use the generic error handler anyway http://xmlsoft.org/html/libxml-xmlerror.html#xmlSetGenericErrorFunc if that fails try the structured error handling http://xmlsoft.org/html/libxml-xmlerror.html#xmlSetStructuredErrorFunc But I think both are linked to the same error gathering entry point in the library so contrary to what the description may led to think it will work. The point is that you can override those default error reporting by using per parsing context specific handlers, but IMHO with the structured error handler it's probably better to keep one entry point (unless you are writing a library in which case you should try to avoid the global setting). Daniel -- Daniel Veillard | Red Hat http://redhat.com/ [EMAIL PROTECTED] | libxml GNOME XML XSLT toolkit http://xmlsoft.org/ http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/ _______________________________________________ xml mailing list, project page http://xmlsoft.org/ [email protected] http://mail.gnome.org/mailman/listinfo/xml
