|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2005-12-31 02:10 UTC] sniper@php.net
[2005-12-31 03:25 UTC] auroraeosrose at gmail dot com
[2005-12-31 03:38 UTC] sniper@php.net
[2005-12-31 04:20 UTC] judas dot iscariote at gmail dot com
[2005-12-31 04:33 UTC] auroraeosrose at gmail dot com
[2005-12-31 08:33 UTC] tony2001@php.net
[2006-01-01 17:43 UTC] andrey@php.net
[2006-01-01 18:29 UTC] andrey@php.net
[2006-01-02 16:59 UTC] auroraeosrose at gmail dot com
[2006-01-02 23:28 UTC] sniper@php.net
[2006-01-03 02:23 UTC] auroraeosrose at gmail dot com
[2006-01-10 17:48 UTC] georg@php.net
[2006-01-10 21:20 UTC] auroraeosrose at gmail dot com
[2006-01-13 11:53 UTC] vrana@php.net
[2006-01-16 16:59 UTC] auroraeosrose at gmail dot com
[2006-01-24 13:28 UTC] georg@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Oct 26 04:00:01 2025 UTC |
Description: ------------ Using mysqli_stmt_fetch or $stmt->fetch crashes apache/php Broken with both mysql 5.0 and 4.1 Reproduce code: --------------- $mysqli = mysqli_connect("localhost", "root", "password", "db"); $mysqli->query("CREATE TABLE IF NOT EXISTS temp (id INT NOT NULL)"); $mysqli->query("INSERT INTO temp (id) VALUES (1),(2),(3),(4)"); $stmt = $mysqli->prepare("SELECT id FROM temp"); $stmt->execute(); $stmt->bind_result($id); $stmt->fetch(); var_dump($id); $stmt->close(); $mysqli->query("DROP TABLE temp"); $mysqli->close(); Expected result: ---------------- 1 Actual result: -------------- Apache/php go boom - I'd send a backtrace but until I get nice "I'm on windows and don't do C" directions that's not going to happen I have the annoying windows dump files if they're even useful trying the same thing procedural style does the same thing - through commenting out trial and error the actual crash occurs on the $stmt->fetch() line