Re: PHP Memory issues in PHP5 as well?
| From: | Andrei Zmievski | Date: | Fri, 26 May 2006 07:18:38 +0000 |
| Subject: | Re: PHP Memory issues in PHP5 as well? | ||
| References: | 1 2 3 | Groups: | php.gtk.general |
| Request: | Send a blank email to php-gtk-general+get-6951@lists.php.net to get a copy of this message | ||
That's not true.
-Andrei
On May 26, 2006, at 4:28 AM, Alan Knowles wrote:
From what I remember you had to turn of the Zend memory manager to make it free memory. (changing the value of a flag in the Zend engine.) Regards Alan Christian Weiske wrote:Benjamin,--PHP-GTK General Mailing List (http://gtk.php.net/) To unsubscribe, visit: http://www.php.net/unsub.phpBut, based on this thread, that may well turn out to be a very bad idea, leading to stability problems. Are these memory issues (not freeing memory when allocated inside a function or PHP class object) also present in PHP5?PHP5 does free memory when unsetting variables. In fact, you can do this: while (true) { $w = new GtkWindow(); } In PHP-Gtk1 (with php4), you would fill up memory within seconds. In PHP5 with PHP-Gtk2, memory usage stays low as the objects are deleted when they aren't used any more. You also can use unset() to free mem, now.