|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2004-07-29 22:09 UTC] bo at theaddedones dot com
[2004-07-30 09:09 UTC] chregu@php.net
[2004-07-30 17:41 UTC] bo at theaddedones dot com
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Oct 27 05:00:01 2025 UTC |
Description: ------------ I know this issue has been resolved in PHP 5.0 using DomDocument::loadXML, BUT in non 5.0 versions, the loading of string XML (memmory) bits has some serious garbage collection problems...namely repeated calls to domxml_open_mem eats the memmory of the system alive.... unsetting variables has no effect.... Reproduce code: --------------- $tt = '<?xml version="1.0" encoding="ISO-8859-1"?> <data> <ff> <rrr>555</rrr> <rrrr>5555</rrrr> <rrrrr>55555</rrrrr> <rrrrrr>555555</rrrrrr> <rrrrrrr>5555555</rrrrrrr> <rrrrrrrr>55555555</rrrrrrrr> <rrrrrrrrr>555555555</rrrrrrrrr> </ff> </data>'; for($i=0;$i<100000;$i++){ $dd = domxml_open_mem($tt); unset($dd); } Expected result: ---------------- not to have the system memory jump by Megabytes...if the loop is left for longer it will eventually chew all resources Actual result: -------------- massive eating of memmory