Mantis - Quercus
Viewing Issue Advanced Details
1860 minor always 07-09-07 19:03 07-20-07 16:42
toomasr  
nam  
normal  
closed 3.1.2  
fixed  
none    
none 3.1.3  
0001860: imagepng() - illegal utf8 encoding
Using Quercus as JSR223 scriptengine the version is SVN trunk. Stacktrace attached. PHP code is sample from http://ee2.php.net/manual/en/function.imagecreate.php [^]

----------------- PHP -----------------
$im = @imagecreate(110, 20)
    or die("Cannot Initialize new GD image stream");
$background_color = imagecolorallocate($im, 0, 0, 0);
$text_color = imagecolorallocate($im, 233, 14, 91);
imagestring($im, 1, 5, 5, "A Simple Text String", $text_color);
imagepng($im);
imagedestroy($im);
--------------- EOF PHP ---------------

Produces an java.io.CharConversionException: illegal utf8 encoding from com.caucho.vfs.ReaderWriterStream.write. It seems the bytes in the image are checked for being UTF8 characters which fails.
 stacktrace.txt [^] (4,783 bytes) 07-09-07 19:03

Notes
(0002121)
nam   
07-20-07 16:42   
php/2149