Skip to content

Commit 177ae4e

Browse files
hoogi91Naktibalda
authored andcommitted
[Db] Fix sqlite connection close when holding reference in PHP's GC (#5557)
1 parent c712a11 commit 177ae4e

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/Codeception/Lib/Driver/Sqlite.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ public function __construct($dsn, $user, $password, $options = null)
2525
public function cleanup()
2626
{
2727
$this->dbh = null;
28+
gc_collect_cycles();
2829
file_put_contents($this->filename, '');
2930
$this->dbh = self::connect($this->dsn, $this->user, $this->password);
3031
}

0 commit comments

Comments
 (0)