|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #11304 memory leak
Submitted: 2001-06-06 02:15 UTC Modified: 2001-08-20 10:40 UTC
From: tgagne at efinnet dot com Assigned:
Status: Closed Package: DOM XML related
PHP Version: 4.0.5 OS: RHat 6.2
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Bug Type:
From: tgagne at efinnet dot com
New email:
PHP Version: OS:


 [2001-06-06 02:15 UTC] tgagne at efinnet dot com
php_domxml.c, line #698

The pointer (content) from xmlNodeGetContent(last); needs to be freed.  There's still another memory leak in domxml but it leaks much slower now.  To my version of the file I added:

if (content) {
    add_property_stringl(child, "content", (char *) content, strlen(content), 1);

directly beneath it.


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2001-06-06 02:18 UTC] tgagne at efinnet dot com
This (I think) is a new bug with (libxml2-2.3.9-1)
 [2001-07-17 10:49 UTC]
This is great. Do you have a test case for this bug?
 [2001-08-20 10:40 UTC]
No feedback. Reopen if you still have this problem
with PHP 4.0.7 (soon to be released) or with latest CVS 
snapshot from

Side note: The libxml version required now is libxml2-2.4.2


PHP Copyright © 2001-2023 The PHP Group
All rights reserved.
Last updated: Sun Oct 01 13:01:24 2023 UTC