Bug #53737 [Opn->Fbk]: segfault / php crash on nl2br(object)

From: Date: Thu, 13 Jan 2011 14:58:20 +0000
Subject: Bug #53737 [Opn->Fbk]: segfault / php crash on nl2br(object)
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-157887@lists.php.net to get a copy of this message
Edit report at http://bugs.php.net/bug.php?id=53737&edit=1 ID: 53737 Updated by: cataphract@php.net Reported by: martin at veverka dot eu Summary: segfault / php crash on nl2br(object) -Status: Open +Status: Feedback Type: Bug Package: Strings related Operating System: gentoo 1.12.14, FreeBSD 8.0 PHP Version: 5.3.5 Block user comment: N Private report: N New Comment: I can't reproduce: $ ~/php/php5.3-t/bin/php -r "echo nl2br(new mysqli);" Warning: nl2br() expects parameter 1 to be string, object given in Command line code on line 1 I also find no problem in nl2br (all pretty standard). Can you give more details? Previous Comments: ------------------------------------------------------------------------ [2011-01-13 14:58:10] martin at veverka dot eu Description: ------------ Calling nl2br(any_object) causes segmentation fault and crashing php. Test script: --------------- <?php // any object echo nl2br(new mysqli()); Expected result: ---------------- fatal error is expected Catchable fatal error: Object of class mysqli could not be converted to string in - on line 3 Actual result: -------------- segfault and php crash dmesg shows this: [12476.986676] php-cgi[21195]: segfault at 3118 ip 00007ff86c5d6074 sp 00007fff1edd4e60 error 4 in php-cgi[7ff86c26f000+77e000] ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/bug.php?id=53737&edit=1

« previous php.bugs (#157887) next »