php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #37344 Crash with PDO and user-defined exception handler
Submitted: 2006-05-07 01:06 UTC Modified: 2006-05-07 01:19 UTC
From: spaze-bugs at exploited dot cz Assigned:
Status: Not a bug Package: Reproducible crash
PHP Version: 5.1.4 OS: WinXP/SP2
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: spaze-bugs at exploited dot cz
New email:
PHP Version: OS:

 

 [2006-05-07 01:06 UTC] spaze-bugs at exploited dot cz
Description:
------------
PHP crashes when using user-defined exception handler to handle PDO expcetions.

Reproduce code:
---------------
function exception_handler($exception) {
	echo 'Uncaught exception: ', $exception->getMessage(), "\n";
}

set_exception_handler('exception_handler');
$dbh = new PDO('mysql:host=mysql41.localhost;port=3306;dbname=foo');


Expected result:
----------------
Uncaught exception: SQLSTATE[28000] [1045] Access denied for user 'ODBC'@'localhost2' (using password: NO)

Actual result:
--------------
Crash with this line in Apache(/2.0.58) errorlog:

[Sun May 07 03:01:26 2006] [notice] Parent: child process exited with status 3221225477 -- Restarting.


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2006-05-07 01:19 UTC] spaze-bugs at exploited dot cz
Uh, sorry, I forgot to disable the APD. When I do NOT load this extension, it works as expected. Sorry for wasting your time.
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Sun Jul 06 07:01:33 2025 UTC