ID: 28713 Updated by: [EMAIL PROTECTED] Reported By: rodolfo at rodsoft dot org -Status: Open +Status: Bogus Bug Type: Reproducible crash Operating System: linux 2.6.6 PHP Version: 5.0.0RC2 New Comment:
Thank you for taking the time to write to us, but this is not a bug. Please double-check the documentation available at http://www.php.net/manual/ and the instructions on how to report a bug at http://bugs.php.net/how-to-report.php The only way in which PHP is allowed to crash is in this case: unlimited recursive calling of functions. Previous Comments: ------------------------------------------------------------------------ [2004-06-09 20:05:35] rodolfo at rodsoft dot org Description: ------------ This ill-behaved code crashes php. I know one should never write things like this, but this sample is an oversimplified version of a much bigger code I'm working with, and I've just spot my error after trying to simplify the code to attach here. PHP should emmit a warning when such things happen, as with __set and __get, saying that $this->func() isn't defined, when called inside a __call handler. Reproduce code: --------------- <? class test { function __call($func, $args) { $this->hello(); } } $a = new test; $a->hello(); echo "You won't read this"; ?> Expected result: ---------------- A warning saying that $this->hello isn't defined. Actual result: -------------- The coredump is a bunch of #0 0x0821d843 in zend_call_function () #1 0x0821e76a in call_user_function_ex () #2 0x0823cfa5 in zend_std_call_user_call () #3 0x0825f8ee in zend_do_fcall_common_helper () #4 0x0825faf1 in zend_do_fcall_by_name_handler () #5 0x0824daf8 in execute () repeated over and over ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=28713&edit=1
