From: cjbj at hotmail dot com Operating system: n/a PHP version: 5.1.4 PHP Bug Type: OCI8 related Bug description: Unnecessary call to OCITransRollback() at the end of request
Description: ------------ Php_oci_persistent_helper() calls php_oci_connection_rollback() without checking connection->needs_commit. This results in an unnecessary call to OCITransRollback() at the end of request for persistent connections. Reproduce code: --------------- <?php echo "<pre>"; oci_internal_debug(1); $conn = oci_pconnect("hr", "hr", "//localhost/XE"); $query = 'select * from dual'; $stid = oci_parse($conn, $query); oci_execute($stid, OCI_DEFAULT); oci_rollback($conn); echo "</pre>"; ?> Expected result: ---------------- ... OCI8 DEBUG: OCITransRollback at (/tmp/php-5.1.3/ext/oci8/oci8.c:1400) OCI8 DEBUG: OCIStmtRelease at (/tmp/php-5.1.3/ext/oci8/oci8_statement.c:589) ... Actual result: -------------- ... OCI8 DEBUG: OCITransRollback at (/tmp/php-5.1.3/ext/oci8/oci8.c:1400) OCI8 DEBUG: OCITransRollback at (/tmp/php-5.1.3/ext/oci8/oci8.c:1400) OCI8 DEBUG: OCIStmtRelease at (/tmp/php-5.1.3/ext/oci8/oci8_statement.c:589) ... -- Edit bug report at http://bugs.php.net/?id=37392&edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=37392&r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=37392&r=trysnapshot52 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=37392&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=37392&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=37392&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=37392&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=37392&r=needscript Try newer version: http://bugs.php.net/fix.php?id=37392&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=37392&r=support Expected behavior: http://bugs.php.net/fix.php?id=37392&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=37392&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=37392&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=37392&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=37392&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=37392&r=dst IIS Stability: http://bugs.php.net/fix.php?id=37392&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=37392&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=37392&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=37392&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=37392&r=mysqlcfg