From: brian at alternate-zone dot com
Operating system: Windows XP
PHP version: 5.2.8
PHP Bug Type: Reproducible crash
Bug description: Apache crashes php5ts.dll
Description:
------------
when I try to make a connection to the database Mysql the Apache HTTP
server crashes.
szAppName: httpd.exe szAppVer: 2.2.11.0 szModName: php5ts.dll
szModVerL 5.2.8.8 offset: 00009fe6
Reproduce code:
---------------
<?php
# Define MySQL Settings
define("MYSQL_HOST", "localhost");
define("MYSQL_USER", "root");
define("MYSQL_PASS", "password");
define("MYSQL_DB", "test");
$conn = mysql_connect("".MYSQL_HOST."", "".MYSQL_USER."",
"".MYSQL_PASS."") or die(mysql_error());
mysql_select_db("".MYSQL_DB."",$conn) or die(mysql_error());
$sql = "SELECT * FROM test";
$res = mysql_query($sql);
while ($field = mysql_fetch_array($res))
{
$id = $field['id'];
$name = $field['name'];
echo 'ID: ' . $field['id'] . '<br />';
echo 'Name: ' . $field['name'] . '<br /><br />';
}
?>
Expected result:
----------------
ID: 1
Name: John
Actual result:
--------------
Apache HTTP Server has encountered a problem and needs to close
--
Edit bug report at http://bugs.php.net/?id=47059&edit=1
--
Try a CVS snapshot (PHP 5.2):
http://bugs.php.net/fix.php?id=47059&r=trysnapshot52
Try a CVS snapshot (PHP 5.3):
http://bugs.php.net/fix.php?id=47059&r=trysnapshot53
Try a CVS snapshot (PHP 6.0):
http://bugs.php.net/fix.php?id=47059&r=trysnapshot60
Fixed in CVS:
http://bugs.php.net/fix.php?id=47059&r=fixedcvs
Fixed in CVS and need be documented:
http://bugs.php.net/fix.php?id=47059&r=needdocs
Fixed in release:
http://bugs.php.net/fix.php?id=47059&r=alreadyfixed
Need backtrace:
http://bugs.php.net/fix.php?id=47059&r=needtrace
Need Reproduce Script:
http://bugs.php.net/fix.php?id=47059&r=needscript
Try newer version:
http://bugs.php.net/fix.php?id=47059&r=oldversion
Not developer issue:
http://bugs.php.net/fix.php?id=47059&r=support
Expected behavior:
http://bugs.php.net/fix.php?id=47059&r=notwrong
Not enough info:
http://bugs.php.net/fix.php?id=47059&r=notenoughinfo
Submitted twice:
http://bugs.php.net/fix.php?id=47059&r=submittedtwice
register_globals:
http://bugs.php.net/fix.php?id=47059&r=globals
PHP 4 support discontinued: http://bugs.php.net/fix.php?id=47059&r=php4
Daylight Savings: http://bugs.php.net/fix.php?id=47059&r=dst
IIS Stability:
http://bugs.php.net/fix.php?id=47059&r=isapi
Install GNU Sed:
http://bugs.php.net/fix.php?id=47059&r=gnused
Floating point limitations:
http://bugs.php.net/fix.php?id=47059&r=float
No Zend Extensions:
http://bugs.php.net/fix.php?id=47059&r=nozend
MySQL Configuration Error:
http://bugs.php.net/fix.php?id=47059&r=mysqlcfg