ID: 28978 Updated by: [EMAIL PROTECTED] Reported By: pumuckel at metropolis dot de Status: Closed Bug Type: OCI8 related Operating System: Linux PHP Version: 4.3.7 Assigned To: tony2001 New Comment:
Yep, I consider it more as a feature request, than a bugfix, so I think it should go into HEAD only. Previous Comments: ------------------------------------------------------------------------ [2004-07-15 01:46:34] pumuckel at metropolis dot de Changes are not committed to 4.3.8 :-( ------------------------------------------------------------------------ [2004-07-12 09:42:59] [EMAIL PROTECTED] This bug has been fixed in CVS. Snapshots of the sources are packaged every three hours; this change will be in the next snapshot. You can grab the snapshot at http://snaps.php.net/. Thank you for the report, and for helping us make PHP better. ------------------------------------------------------------------------ [2004-07-05 11:33:54] [EMAIL PROTECTED] I'll take a look at it. ------------------------------------------------------------------------ [2004-06-30 21:44:51] pumuckel at metropolis dot de Description: ------------ Calling OCIBindByName on the same placeholder (same statement) does eat memory. The expected behaviour should be to just replace the old placeholder variable with the new one, without any new memory allocation needed. Reproduce code: --------------- <? // http://download-west.oracle.com/docs/cd/B10501_01/appdev.920/a96584/oci05bnd.htm#421792 ob_end_flush(); ob_implicit_flush(1); $conn = OCILogon("scott", "tiger", "database"); $stmt = OCIParse($conn, "SELECT DUMMY FROM DUAL WHERE DUMMY=:DUMMY"); $i = 1; while($i++) { OCIBindByName($stmt, ":DUMMY", &$dummy, 1); if ($i%500 == 0) echo "\rMEM -send $i: ".memory_get_usage(); } ?> Expected result: ---------------- The memory usage shouldn't grow. A second call to ocibindbyname on the same placeholder should free/replace the old php internal bind variable (in oci8.c) for this placeholder... Actual result: -------------- actual a new bind place holder is allocated and added to the list of bind variables. ./bug.php MEM -send 122500: 8387128 Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 20 bytes) in /user/bug.php on line 16 ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=28978&edit=1