Edit report at https://bugs.php.net/bug.php?id=62456&edit=1

 ID:                 62456
 Comment by:         Sjon at hortensius dot net
 Reported by:        iblacksmoke at gmail dot com
 Summary:            Incorrect description of notice
 Status:             Open
 Type:               Bug
 Package:            I18N and L10N related
 Operating System:   debian linux
 PHP Version:        5.4.4
 Block user comment: N
 Private report:     N

 New Comment:

If you suspect that this is caused by encoding in your script, can't you post 
an 
example that actually contains these characters? Because your current 
test-script 
works fine here.

Maybe you can post an example with eval and chr?


Previous Comments:
------------------------------------------------------------------------
[2012-06-30 22:57:59] iblacksmoke at gmail dot com

Description:
------------
Description of notice when calling missing property of standard php object 
contains incorrect characters (possibly from different encoding). They cause 
error in class of standard class ErrorException, and script returns fatal 
error(with no information) rather than exception. It turns out there as much as 
two bugs: incorrect encoding of strings and lack of data filtering in 
ErrorException constructor.

Test script:
---------------
one:
$test = new StdClass();
echo $test->qwerty;


two:
set_error_handler(function($errno, $errstr, $errfile, $errline){
        throw new ErrorException($errstr, 0, $errno, $errfile, $errline);
});

$test = new StdClass();
echo $test->qwerty;

Expected result:
----------------
one:
Notice: Undefined property: stdClass::$qwerty in script

two:
correct php exception

Actual result:
--------------
one:
Notice: Undefined property: stdClass�K�::$qwerty in script

two:
Fatal error: in script


------------------------------------------------------------------------



-- 
Edit this bug report at https://bugs.php.net/bug.php?id=62456&edit=1

Reply via email to