|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2006-06-28 16:27 UTC] tony2001@php.net
[2006-07-06 01:00 UTC] php-bugs at lists dot php dot net
[2007-01-04 17:24 UTC] abaker_php at yahoo dot com
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Nov 07 23:00:01 2025 UTC |
Description: ------------ When $smarty->debugging = true and using $smarty->assign to assign a template variable with the value of $errcontext, PHP segfaults when trying to output the debugging console for Smarty. Reproduce code: --------------- <? include('Smarty.class.php'); $smarty = new Smarty(); $smarty->debugging = true; // the error will not occur if debugging = false set_error_handler("error_handler",E_ALL); function error_handler($errno, $errstr, $errfile, $errline, $errcontext) { global $smarty; $smarty->assign('killme',$errcontext); $smarty->display('killsmarty.tpl'); // this file can be empty but it has to exist echo($errstr); } trigger_error("Uh-ho!",E_USER_ERROR); ?> Expected result: ---------------- $errcontext should be assigned to Smarty template variable $killme. Actual result: -------------- #0 0xb7a56e40 in vfprintf () from /lib/tls/libc.so.6 #1 0xb7a73ffb in vsprintf () from /lib/tls/libc.so.6 #2 0xb7a5fe1e in sprintf () from /lib/tls/libc.so.6 #3 0x08277eb1 in _convert_to_string () #4 0x0827f684 in zend_make_printable_zval () #5 0x08277a1c in concat_function () #6 0x082a2b7e in execute () #7 0x0829d9c8 in execute () #8 0x0829bf83 in zend_get_user_opcode_handler () #9 0x00000000 in ?? ()