php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #35303 PDO prepare crashes
Submitted: 2005-11-20 12:50 UTC Modified: 2005-11-21 12:39 UTC
From: stochnagara at hotmail dot com Assigned:
Status: Closed Package: PDO related
PHP Version: 5CVS-2005-11-20 (snap) OS: windows xp
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: stochnagara at hotmail dot com
New email:
PHP Version: OS:

 

 [2005-11-20 12:50 UTC] stochnagara at hotmail dot com
Description:
------------
PDO still crashes Apache when using child classes.
See bug #35118 - it's almost the same.

Reproduce code:
---------------
<?
class MAppPDOStatement extends PDOStatement {
}

class MAppPDO extends PDO {
	function prepare ($string, array $options = array()) {
		$options [PDO::ATTR_STATEMENT_CLASS] = 'MAppPDOStatement';
		parent::prepare ($string, $options);
	}
}

$a = new MAppPDO("sqlite::memory:");
$a->prepare("insert into test (b) values (?)");


Expected result:
----------------
no errors

Actual result:
--------------
Apache crashes.

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-11-20 21:07 UTC] iliaa@php.net
This bug has been fixed in CVS.

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.


 [2005-11-21 12:39 UTC] stochnagara at hotmail dot com
Actually I cannot check if the bug is fixed because there has been a compilation error for 5.1 snap in spans.php.net for about 20 hours.
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Thu Jan 30 02:01:30 2025 UTC