After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 643949 - There is possible memory leak if xmlParserInputBufferCreateIO is failed.
There is possible memory leak if xmlParserInputBufferCreateIO is failed.
Status: RESOLVED FIXED
Product: libxml2
Classification: Platform
Component: general
2.7.8
Other All
: Normal normal
: ---
Assigned To: Daniel Veillard
libxml QA maintainers
Depends on:
Blocks:
 
 
Reported: 2011-03-05 14:40 UTC by Lin Yi-Li
Modified: 2012-05-10 08:21 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch for this problem. (3.94 KB, patch)
2011-03-05 14:40 UTC, Lin Yi-Li
none Details | Review

Description Lin Yi-Li 2011-03-05 14:40:23 UTC
Created attachment 182549 [details] [review]
Patch for this problem.

For example, ioctx will be closed through xmlFreeParserInputBuffer (directly or indirectly) before the function is returned except xmlParserInputBufferCreateIO is failed.
Comment 1 André Klapper 2012-02-03 13:36:42 UTC
Comment on attachment 182549 [details] [review]
Patch for this problem.

[Setting "patch" flag and correcting mime type so this can actually be queried for.]
Comment 2 Daniel Veillard 2012-05-10 08:21:19 UTC
Thanks Andre' for the triaging :-)

The intent of the patch is good but there is a problem in the sense
that it is legal to pass a NULL ioclose function. So I had to modify
the patch to take this into account to avoid a crash in that situation.
I commited the resulting patch:

http://git.gnome.org/browse/libxml2/commit/?id=24464be6390bc61a0f0e17890fbfc9c581434e29

 thanks a lot !

Daniel