Bug #66843 [Com]: set_error_handler message is cut

From: Date: Fri, 07 Mar 2014 12:41:50 +0000
Subject: Bug #66843 [Com]: set_error_handler message is cut
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-184601@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=66843&edit=1 ID: 66843 Comment by: php at maisqi dot com Reported by: php at maisqi dot com Summary: set_error_handler message is cut Status: Open Type: Bug Package: *General Issues Operating System: Windows and Linux PHP Version: 5.5.10 Block user comment: N Private report: N New Comment: Test script in http://maisqi.com/outros/bugs/php/66843, running on a Linux server. Previous Comments: ------------------------------------------------------------------------ [2014-03-07 12:39:38] php at maisqi dot com Description: ------------ The message passed to the function registered with set_error_handler is sometimes cut. I tested the error reporting with or without set_error_handler() and the message is incomplete on the latter. Test script: --------------- <pre> <?php ini_set ('display_errors', '1'); echo "<h2>With no set_error_handler()</h2>\n"; test (); echo "<h2>With the set_error_handler() setup</h2>\n"; set_error_handler (function ($code, $message) { echo '== ', htmlspecialchars ($message); }); test (); echo "\n\n\n\nDone"; function test ($a) {} Expected result: ---------------- It should be output the exact same message two times. Actual result: -------------- The first message (with no set_error_handler() is ok; the second is trimmed after "defined". ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=66843&edit=1

« previous php.bugs (#184601) next »