Edit report at http://bugs.php.net/bug.php?id=51648&edit=1
ID: 51648 User updated by: shooreek at gmail dot com Reported by: shooreek at gmail dot com Summary: Memory leak in infinite loop Status: Open Type: Bug Package: SQLite related Operating System: WinXP SP3 PHP Version: 5.3.2 New Comment: Now I cannot provide exact information about modification of php.ini, but I can provide it later (two week's holiday). I modified memory_limit, post_max_size, extension_dir, uncommented some extensions like misql, mysqli, pdo_sqlite, sqlite3, curl. Nothing serious, only extensions from binary VC6 x86 Thread Safe (2010-Mar-04 20:11:08). As you can see, memory leak rate is not so great. You cannot reproduce leak at all, can you? Previous Comments: ------------------------------------------------------------------------ [2010-05-07 16:51:42] crrodriguez at opensuse dot org Cannot reproduce in linux, tell us if you have 3rd party extensions installed as well if you have modified php.ini. maybe Pierre can check this one out.. ------------------------------------------------------------------------ [2010-05-07 13:19:50] shooreek at gmail dot com Pakage changed to SQLite related ------------------------------------------------------------------------ [2010-05-04 11:48:26] shooreek at gmail dot com cbandy, you are right: with UPDATE or SELECT queries mem usage remains constant. But with INSERT queries mem usage grows up. I discovered some way to free this memory: you should unlink SQLite DB file and create new one, because $db->close() is _not_ enough! May be there are another ways to do it, but I do not know about their existence. May be someone knows? I think it real bug and it should be fixed. So, it is SQLite extension related bug. There is no such problem in Mysqli. P.S. I first post I wrote that Mysqli have the same problem as SQLite. My fault. The problem was in multiple calls mysqli_init() function. With SELECT, UPDATE, INSERT or UPDATE commands Mysqli do not have memory leaks. If memory leaks related with multiple mysqli_init() calls is a bug, I can report it in separate. Just let me know. Thank you for your attention. ------------------------------------------------------------------------ [2010-05-02 16:24:23] cbandy at jbandy dot com Inserting an infinite number of rows could easily lead to mem usage within SQLite (not PHP). By executing only UPDATE in the loop, DB size should stay constant. Then results should show PHP-SQLite execution leaks. ------------------------------------------------------------------------ [2010-04-24 18:43:44] fel...@php.net I can't reproduce it on Linux. ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/bug.php?id=51648 -- Edit this bug report at http://bugs.php.net/bug.php?id=51648&edit=1