From: perry dot sebastian at gmail dot com Operating system: linux - SUSE 10 PHP version: 5.1.2 PHP Bug Type: Scripting Engine problem Bug description: Adding arbitary expression to class cause premature end to script
Description: ------------ Adding a line of code to a specific object class causes the web application to terminate prematurely. A line of code such as "function testthis() {}" will trigger this problem. When this line is commented out, the application behaves as expected. Code previously worked under PHP 4.4. Reproduce code: --------------- <?php // class DataCon is data container class DataCon { //defined variables function __construct() {} function init( $args, &$dbh ) { // init object } // various functions for getting and setting data # multiple # lines of code # commented out } ?> Expected result: ---------------- Web page with printed output of application states at the top of the page. Actual result: -------------- This problem seems to be isolated with this class file. I have turned on STRICT for error reporting, but no error relevant to this object comes back when the application is executed. I cleaned line endings, changed function names, removed and added code, and the problem persists. Apache does not report an error. Premature termination is also very strange. It seems very inconsistent. Initially an error occurred that flagged an included file for consuming too much memory. This error stopped after the error was investigated (and I have not been able to replicate this error). The failure appears to "reach back" in the code execution and stop application output before the point of failure (noted by various print statement track code execution). Forcing an exit of the application before loading this object class causes termination at the appropriate point - not before. -- Edit bug report at http://bugs.php.net/?id=36229&edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=36229&r=trysnapshot44 Try a CVS snapshot (PHP 5.1): http://bugs.php.net/fix.php?id=36229&r=trysnapshot51 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=36229&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=36229&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=36229&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=36229&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=36229&r=needscript Try newer version: http://bugs.php.net/fix.php?id=36229&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=36229&r=support Expected behavior: http://bugs.php.net/fix.php?id=36229&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=36229&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=36229&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=36229&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=36229&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=36229&r=dst IIS Stability: http://bugs.php.net/fix.php?id=36229&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=36229&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=36229&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=36229&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=36229&r=mysqlcfg