#23747 [Opn->Fbk]: GD-PNG fatal error

From: Date: Thu, 22 May 2003 13:13:07 +0000
Subject: #23747 [Opn->Fbk]: GD-PNG fatal error
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-40192@lists.php.net to get a copy of this message
ID: 23747 Updated by: derick@php.net Reported By: rryda at mgedata dot cz -Status: Open +Status: Feedback Bug Type: GD related Operating System: Windows 2000 PHP Version: 4.3.2RC4 New Comment: It just looks like your image is broken, can you put up a runnable script + image in a tarball (or send it to me by mail) to verify? Derick Previous Comments: ------------------------------------------------------------------------ [2003-05-22 06:15:23] rryda at mgedata dot cz More info: - PHP is run as CGI - using original windows binary pack - php_gd2.dll from original windows binary pack - web server: Apache 2.0.45 Imagecreatefrompng() is used in following code: //$image_file_url ... URL to the source 24-bit PNG file $image_base = ImageCreateTrueColor($map_width, $map_height); $white = ImageColorExact($image_base, 255, 255, 255); ImageFill($image_base, 0, 0, $white); // ........ $input = fopen($image_file_url, "rb"); $image_data = fread($input, 2000000); fclose($input); $image_file = tempnam("", "gd".rand(0, 10000)); $output = fopen($image_file, "w+b"); fwrite($output, $image_data); fclose($output); $image_tmp = ImageCreateFromPNG($image_file); // ERROR // ........ ------------------------------------------------------------------------ [2003-05-22 05:56:11] derick@php.net Not enough information was provided for us to be able to handle this bug. Please re-read the instructions at http://bugs.php.net/how-to-report.php If you can provide more information, feel free to add it to this bug and change the status back to "Open". Thank you for your interest in PHP. ------------------------------------------------------------------------ [2003-05-22 02:33:22] rryda at mgedata dot cz Fatal error: imagecreatefrompng(): gd-png: fatal libpng error: IDAT: CRC error in ..... The error appears only if PHP is run as CGI (php.exe). This functionality was used in 4.3.2RC3 successfully. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=23747&edit=1

« previous php.bugs (#40192) next »