From: sruwhof at intervisionit dot nl
Operating system: *
PHP version: 5.0.4
PHP Bug Type: Reproducible crash
Bug description: Apache crashes when type hints are used in a method
Description:
------------
Apache crashes when type hints are used in a method. An important term for
this is that the result of the method is not saved. If you do save the
result in a variable, then Apache won't crash.
My config:
PHP 5.0.4 (cli) build mar 31 2005 02:45:48
Apache 2.0.54
Windows XP SP 2
PHP runs as an apache module.
Reproduce code:
---------------
<?php
# apache crashes
class a {
public function a (b $p) {}
}
class b {}
new a(new b); // result is _not_ saved in a variable
?>
<?php
# apache doesn't crash
class a {
public function a (b $p) {}
}
class b {}
$a = new a(new b); //result is saved in a variable
?>
Expected result:
----------------
Apache crashes
--
Edit bug report at http://bugs.php.net/?id=33036&edit=1
--
Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=33036&r=trysnapshot4
Try a CVS snapshot (php5.0):
http://bugs.php.net/fix.php?id=33036&r=trysnapshot50
Try a CVS snapshot (php5.1):
http://bugs.php.net/fix.php?id=33036&r=trysnapshot51
Fixed in CVS: http://bugs.php.net/fix.php?id=33036&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=33036&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=33036&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=33036&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=33036&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=33036&r=support
Expected behavior: http://bugs.php.net/fix.php?id=33036&r=notwrong
Not enough info:
http://bugs.php.net/fix.php?id=33036&r=notenoughinfo
Submitted twice:
http://bugs.php.net/fix.php?id=33036&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=33036&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=33036&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=33036&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=33036&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=33036&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=33036&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=33036&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=33036&r=mysqlcfg