ID:               16841
 Updated by:       [EMAIL PROTECTED]
 Reported By:      [EMAIL PROTECTED]
-Status:           Feedback
+Status:           Closed
 Bug Type:         GD related
 Operating System: Linux
 PHP Version:      4.2.0
 New Comment:



I think this is the same libgd / libpng 1.2 incompability as we saw
before.
If you downgrade to libpng 1.0.9 it should work fine. Can you try
this?

Derick


Previous Comments:
------------------------------------------------------------------------

[2002-04-26 01:00:32] [EMAIL PROTECTED]

Tested here as well and not able to reproduce.  I got a proper PNG. 
(PHP HEAD and GD-2.0.1) 
This smells like a local libpng problem to me.  The segfault is deep
inside libpng.

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

[2002-04-25 23:00:47] [EMAIL PROTECTED]

This one looks really strange. It looks like your libpng has some
problems. I've the same libs installed and just tested it and it works
wihout problems.

Can you try cleanly uninstalling it completely from your system and
re-installing it [libpng] (best is to try a stable release directly and
not the same as you had intalled already on your system).

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

[2002-04-25 22:50:44] [EMAIL PROTECTED]

backtrace follows:

#0  0xa81 in ?? ()
#1  0x400d1468 in png_create_write_struct_2 () from
/usr/lib/libpng.so.3
#2  0x400d12c9 in png_create_write_struct () from /usr/lib/libpng.so.3
#3  0x8169099 in gdImagePngCtx ()
#4  0x80ef360 in _php_image_output_ctx (ht=1, return_value=0x8210fe4,
this_ptr=0x0, return_value_used=0, image_type=2, 
    tn=0x8187b4b "PNG", func_p=0x8169030 <gdImagePngCtx>) at
gd_ctx.c:94
#5  0x80f14be in zif_imagepng (ht=1, return_value=0x8210fe4,
this_ptr=0x0, return_value_used=0) at gd.c:1479
#6  0x815436a in execute (op_array=0x82111ac) at ./zend_execute.c:1598
#7  0x80cf919 in zend_execute_scripts (type=8, retval=0x0,
file_count=3) at zend.c:810
#8  0x806b3f1 in php_execute_script (primary_file=0xbffff9c4) at
main.c:1381
#9  0x8065821 in main (argc=2, argv=0xbffffa54) at cgi_main.c:785
#10 0x4019774f in __libc_start_main () from /lib/libc.so.6

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

[2002-04-25 22:15:41] [EMAIL PROTECTED]

To properly diagnose this bug, we need a backtrace to see what is
happening behind the scenes. To find out how to generate a backtrace,
please read http://bugs.php.net/bugs-generating-backtrace.php

Once you have generated a backtrace, please submit it to this bug
report and change the status back to "Open".



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

[2002-04-25 21:23:20] [EMAIL PROTECTED]

<?php
header ("Content-type: image/png");
$im = @imagecreate (50, 100)
    or die ("Cannot Initialize new GD image stream");
$background_color = imagecolorallocate ($im, 255, 255, 255);
$text_color = imagecolorallocate ($im, 233, 14, 91);
imagestring ($im, 1, 5, 5,  "A Simple Text String", $text_color);
imagepng ($im);
?>

generates a reproducable segfault in DSO, CGI and CLI versions. GD is
version 1.8.4, although segfaults also occurred with 2.0.1. Libpng is
1.2.1, zlib is 1.1.4.

Compiling PHP 4.1.2 identically does not produce the segfault.

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


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

Reply via email to