#34809 [Opn->Asn]: PDO FETCH_INTO crashes Apache

From: Date: Mon, 10 Oct 2005 11:05:15 +0000
Subject: #34809 [Opn->Asn]: PDO FETCH_INTO crashes Apache
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-86337@lists.php.net to get a copy of this message
ID: 34809 Updated by: sniper@php.net Reported By: stochnagara at hotmail dot com -Status: Open +Status: Assigned Bug Type: PDO related Operating System: windows xp PHP Version: 5CVS-2005-10-10 (snap) -Assigned To: +Assigned To: wez New Comment: Assigned to the maintainer. Previous Comments: ------------------------------------------------------------------------ [2005-10-10 13:03:23] stochnagara at hotmail dot com Sorry, "General error: PDO_FETCH_FUNC is only allowed in" should be read as "General error: PDO_FETCH_INTO is only allowed in" or just fetch record in mode FETCH_INTO if this is allowed. ------------------------------------------------------------------------ [2005-10-10 12:58:41] stochnagara at hotmail dot com Description: ------------ The code bellow crashes Apache server. The crash is similar to bug #34802 but the crash code is quite different. Reproduce code: --------------- <? $pdo = new PDO('mysql:host=localhost;dbname=borovo'); $sth = $pdo->prepare ('SELECT nid,type FROM node'); $sth->execute(); var_dump ($sth->fetch (PDO::FETCH_INTO, 3)); Expected result: ---------------- Warning: PDOStatement::fetch() [function.fetch]: SQLSTATE[HY000]: General error: PDO_FETCH_FUNC is only allowed in PDOStatement::fetchAll() in C:\Program Files\Apache Group\Apache2\htdocs\boroinvest\test.php on line 5 bool(false) Actual result: -------------- Apache crashes. Log message: Parent: child process exited with status 3221225477 -- Restarting. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=34809&edit=1

« previous php.bugs (#86337) next »