Req #52390 [Asn->Csd]: mysqli_report() should be per-request setting

From: Date: Fri, 13 Aug 2010 10:44:38 +0000
Subject: Req #52390 [Asn->Csd]: mysqli_report() should be per-request setting
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-153402@lists.php.net to get a copy of this message
Edit report at http://bugs.php.net/bug.php?id=52390&edit=1

 ID:                 52390
 Updated by:         kalle@php.net
 Reported by:        vrana@php.net
 Summary:            mysqli_report() should be per-request setting
-Status:             Assigned
+Status:             Closed
 Type:               Feature/Change Request
 Package:            MySQLi related
 Operating System:   Irrelevant
 PHP Version:        5.3.2
 Assigned To:        kalle
 Block user comment: N

 New Comment:

This bug has been fixed in SVN.

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.

Fixed in PHP_5_2, PHP_5_3 & trunk


Previous Comments:
------------------------------------------------------------------------
[2010-08-13 12:43:16] kalle@php.net

Automatic comment from SVN on behalf of kalle
Revision: http://svn.php.net/viewvc/?view=revision&revision=302181
Log: Changed mysqli_report() to be per-request specific rather than
per-process specific (Fixes #52390)

------------------------------------------------------------------------
[2010-08-13 12:18:29] kalle@php.net

Could you try the supplied patch that simply resets report_mode to 0 at
every RINIT?

Patch is made off trunk but should apply to any branch

------------------------------------------------------------------------
[2010-08-13 12:17:12] kalle@php.net

The following patch has been added/updated:

Patch Name: bug-52390
Revision:   1281694631
URL:       
http://bugs.php.net/patch-display.php?bug=52390&patch=bug-52390&revision=1281694631

------------------------------------------------------------------------
[2010-07-21 16:13:29] vrana@php.net

Description:
------------
The report_mode variable set by mysqli_report() should be initialized in
request init instead of global init to achieve a consistent behavior.

Test script:
---------------
<?php
$mysqli = mysqli_connect();
mysqli_query($mysqli, "SEL");
?>


Expected result:
----------------
No error message or exception.

Actual result:
--------------
Nothing, error message or exception depending on mysqli_report() set by
previous request in the same process.


------------------------------------------------------------------------



-- 
Edit this bug report at http://bugs.php.net/bug.php?id=52390&edit=1


Thread (4 messages)

« previous php.bugs (#153402) next »