Edit report at https://bugs.php.net/bug.php?id=63486&edit=1
ID: 63486
Comment by: marcelotpcruz at gmail dot com
Reported by: derick@php.net
Summary: mysqli_free_result leave the resource variable in a
messy state
Status: Assigned
Type: Bug
Package: MySQLi related
PHP Version: 5.4.8
Assigned To: mysql
Block user comment: N
Private report: N
New Comment:
This is fixed at PHP 7.4.9 (cli) (built: Aug 4 2020 11:52:41) ( ZTS Visual C++ 2017 x64 ).
Probably fixed at Version 7.4.3.
You may check for an int property to see if it's freed:
$result->free();
var_dump(isset($result->current_field));//bool(false)
var_dump($result);//object(mysqli_result)#3 (0) {}
Previous Comments:
------------------------------------------------------------------------
[2016-07-21 07:25:49] davey@php.net
Closed accidentally. Reopening.
------------------------------------------------------------------------
[2016-07-20 11:39:18] davey@php.net
Automatic comment on behalf of jpauli
Revision: http://git.php.net/?p=php-src.git;a=commit;h=37ecfdad09767773dfacf478e0c5a66a01f66dca
Log: Fix #63486
------------------------------------------------------------------------
[2015-10-28 22:38:09] php dot net at mellesmoen dot com
I'm seeing this issue as well using:
PHP 5.6.14
Xdebug 2.3.3
MySQL 5.7.9
Though the work around posted by "[2015-01-16 08:57 UTC] hans dot puac at gmail dot com"
fixes the issue and allows me to move forward. ;-)
------------------------------------------------------------------------
[2015-06-04 15:47:02] loco at andrews dot lv
This issue is still there and is extremely annoying, as xdebug is practically unusable, as it's
often impossible to reach a breakpoint due to the state of mysqli_result:
"main(): Couldn't fetch mysqli_result in ...."
error is recorded into the fpm log when setting a breakpoint in PhpStorm, even before a breakpoint
could even be reached..
------------------------------------------------------------------------
[2015-03-10 02:55:31] laruence@php.net
test fails in all branches, and <jpauli> said, he still wait for someone in mysql to review it
then Stas merged it.
thanks
------------------------------------------------------------------------
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
https://bugs.php.net/bug.php?id=63486
--
Edit this bug report at https://bugs.php.net/bug.php?id=63486&edit=1