#45799 [WFx->Asn]: imagepng() crashes on empty image
| From: | pajoye@php.net | Date: | Mon, 01 Dec 2008 11:02:36 +0000 |
| Subject: | #45799 [WFx->Asn]: imagepng() crashes on empty image | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-131512@lists.php.net to get a copy of this message | ||
ID: 45799
Updated by: pajoye@php.net
Reported By: amelek32 at gmail dot com
-Status: Wont fix
+Status: Assigned
Bug Type: GD related
Operating System: Windows XP Pro x64
PHP Version: 5.2.6
Assigned To: pajoye
New Comment:
My bad, you are right!
Previous Comments:
------------------------------------------------------------------------
[2008-12-01 11:00:46] amelek32 at gmail dot com
then
<?
$img = imagecreate(500,500);
@imagepng($img);
imagedestroy($img);
?>
should return empty page..
However, it do not ;)
------------------------------------------------------------------------
[2008-11-30 22:52:48] pajoye@php.net
Well, after a 2nd look, the warning will remain anyway. Whether it is
raised by libgd or php does not change anything > won't fix
------------------------------------------------------------------------
[2008-08-12 14:25:05] pajoye@php.net
> shouldn't it return warning without putting part of header to
output?
Hm, good point. I may add a check before calling the png function and
avoid to much troubles later. I will do it for 5.3+
------------------------------------------------------------------------
[2008-08-12 13:45:49] amelek32 at gmail dot com
shouldn't it return warning without putting part of header to output?
------------------------------------------------------------------------
[2008-08-12 13:37:02] pajoye@php.net
That's libpng behaviors. A PNG palette image must have colors to be
saved.
By the way, warnings are not crashes.
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/45799
--
Edit this bug report at http://bugs.php.net/?id=45799&edit=1