Bug #55377 [Opn->Fbk]: Can't unlock SQLite3 when error occurs in PDOStatement iterating.
| From: | cmb@php.net | Date: | Wed, 02 Jun 2021 14:51:15 +0000 |
| Subject: | Bug #55377 [Opn->Fbk]: Can't unlock SQLite3 when error occurs in PDOStatement iterating. | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-234171@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=55377&edit=1
ID: 55377
Updated by: cmb@php.net
Reported by: riverfish323 at yahoo dot co dot jp
Summary: Can't unlock SQLite3 when error occurs in
PDOStatement iterating.
-Status: Open
+Status: Feedback
Type: Bug
Package: PDO SQLite
Operating System: WindowsXP SP3
PHP Version: 5.3.6
-Assigned To:
+Assigned To: cmb
Block user comment: N
Private report: N
New Comment:
I cannot reproduce this with PHP 7.4 and sqlite3 3.31.1; maybe an
issue with an old PHP or SQLite3 version?
Previous Comments:
------------------------------------------------------------------------
[2011-08-06 18:01:14] riverfish323 at yahoo dot co dot jp
Description:
------------
Sorry for strange Engrish.
SQLite3 database didn't unlock, when fatal error occurs while iterating over a PDOStatement
object using foreach-loop.
Test script:
---------------
$con = new PDO('sqlite:test.db');
$con->query('CREATE TABLE IF NOT EXISTS t (c INT)');
$con->query('INSERT INTO t VALUES (1)');
foreach ($con->query('SELECT * FROM t LIMIT 1') as $row) {
trigger_error('abort', E_USER_ERROR); # test.db not unlocking
}
Expected result:
----------------
Will not be able to use some SQL statements. In addition PHP will be timeout.
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=55377&edit=1