Re: Another issue with invalid XML values - Mailing list pgsql-hackers

From Noah Misch
Subject Re: Another issue with invalid XML values
Date
Msg-id 20110601220207.GB8246@tornado.gateway.2wire.net
Whole thread Raw
In response to Re: Another issue with invalid XML values  (Florian Pflug <fgp@phlo.org>)
Responses Re: Another issue with invalid XML values
List pgsql-hackers
On Wed, Jun 01, 2011 at 06:16:21PM +0200, Florian Pflug wrote:
> On Jun1, 2011, at 03:17 , Florian Pflug wrote:
> > My nagging suspicion is that libxml reports errors like there via some callback function, and only returns a
non-zeroresult if there are structural errors in the XML. But my experience with libxml is pretty limited, so maybe
someonewith more experience in this area can shed some light on this...
 
> 
> As it turns out, this is actually the case.

Thanks for getting to the bottom of this.  I had wondered why, for some versions
of libxml2, xml_in would accept things that xmllint rejected.  Sounds like the
list of errors that actually affect the return code has changed over time.

> Anyway, I'll try to come up with a patch that replaces xmlSetGenericErrorFunc() with xmlSetStructuredErrorFunc().

Sounds sensible.  Will this impose any new libxml2 version dependency?


pgsql-hackers by date:

Previous
From: Noah Misch
Date:
Subject: Re: pg_terminate_backend and pg_cancel_backend by not administrator user
Next
From: Tom Lane
Date:
Subject: Re: pgpool versus sequences