#37925 [NEW]: After a try catch block, the echo doens't work with an exit

From: Date: Tue, 27 Jun 2006 11:05:14 +0000
Subject: #37925 [NEW]: After a try catch block, the echo doens't work with an exit
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-98821@lists.php.net to get a copy of this message
From: batataw at gmail dot com Operating system: Linux Fedora PHP version: 5.1.4 PHP Bug Type: Output Control Bug description: After a try catch block, the echo doens't work with an exit Description: ------------ After a Try/Catch block I used an exit. It's impossible to display all the echos (print, var_dump...) between the Try/Catch block and the exit. I had to use these functions to force the echo : $buffer = ob_get_flush();//hack flush(); exit; Reproduce code: --------------- //Execute Request try{ $sth->execute(); } catch(PDOException $e){ $errmsg = implode(":",$sth->errorInfo()); Error::userErrorHandler(E_USER_WARNING, 'DB Error : '. $errmsg, __FILE__, __LINE__, $errmsg); } ------------------------------------ echo "Message Error"; exit; Expected result: ---------------- Message Error Actual result: -------------- Nothing -- Edit bug report at http://bugs.php.net/?id=37925&edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=37925&r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=37925&r=trysnapshot52 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=37925&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=37925&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=37925&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=37925&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=37925&r=needscript Try newer version: http://bugs.php.net/fix.php?id=37925&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=37925&r=support Expected behavior: http://bugs.php.net/fix.php?id=37925&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=37925&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=37925&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=37925&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=37925&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=37925&r=dst IIS Stability: http://bugs.php.net/fix.php?id=37925&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=37925&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=37925&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=37925&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=37925&r=mysqlcfg

« previous php.bugs (#98821) next »