Re: Heads-Up: Beware of xmlCleanupParser() when your package links against libxml2

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jan 13, 2010 at 04:07:24PM -0500, Tom Lane wrote:
> Lennart Poettering <mzerqung@xxxxxxxxxxx> writes:
> > There's something else that came to my mind: if libxml2 is loaded into
> > memory indirectly because some dlopen'ed module wanted it, and then
> > used, and then unloaded again because the module got dlcose'd again,
> > won't you leak TLS vars unless the xmlCleanupParser() function was
> > called properly before? In that case, not calling xmlCleanupParser()
> > is an error, right? And calling it, too, since some other
> > plugin/thread might still need it. Which means you are in a dilemma:
> > in either case you are doing it wrong.
> 
> Got it in one.  libxml's API in this area is unusably broken, and needs
> a ground-up redesign not random messages telling users that they didn't
> use it right --- there *is* no right way to use it.
> 
> My experience with this comes from the Postgres project, which wasted
> many moons trying to use xmlMemSetup() ... basically, you can't replace
> libxml's memory management, you just have to live with whatever it
> chooses to leak.

  First time I see something coming from you or Postgres group
complaining about a leak or about the use of xmlMemSetup()

Daniel

-- 
Daniel Veillard      | libxml Gnome XML XSLT toolkit  http://xmlsoft.org/
daniel@xxxxxxxxxxxx  | Rpmfind RPM search engine http://rpmfind.net/
http://veillard.com/ | virtualization library  http://libvirt.org/
-- 
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxxx
https://admin.fedoraproject.org/mailman/listinfo/devel

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]
  Powered by Linux