From: thomas at thoftware dot de Operating system: Windows XP PHP version: 4.4.7 PHP Bug Type: Scripting Engine problem Bug description: Errorhandler doesn't work
Description: ------------ Setting an Errorhandler with set_error_handler() and then calling require() with a Function as Argument doesn't produce the expected Result. Reproduce code: --------------- function ehandler($e,$t,$f,$l,$c) { echo $t; } function foo($foo) { return($foo); } set_error_handler('ehandler'); error_reporting(E_ALL); require_once(foo('foo')); Expected result: ---------------- Some Errormessage like this: main(foo) [function.main]: failed to open stream: No such file or directory Fatal error: main() [function.require]: Failed opening required 'foo' (include_path='.;c:\php4\pear') in foo.php on line x Actual result: -------------- Nothing (infinite loop?). PHP crashes. Using no Errorhandler or giving 'foo' directly to require_once() works. -- Edit bug report at http://bugs.php.net/?id=41862&edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=41862&r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=41862&r=trysnapshot52 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=41862&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=41862&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=41862&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=41862&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=41862&r=needscript Try newer version: http://bugs.php.net/fix.php?id=41862&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=41862&r=support Expected behavior: http://bugs.php.net/fix.php?id=41862&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=41862&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=41862&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=41862&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=41862&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=41862&r=dst IIS Stability: http://bugs.php.net/fix.php?id=41862&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=41862&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=41862&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=41862&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=41862&r=mysqlcfg