|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2004-06-05 05:55 UTC] jim at bluedojo dot com
Description:
------------
For some reason, this gif causes the processor to max out at 100% when imageCreateFromGif() function is used.
Reproduce code:
---------------
<?
imageCreateFromGif("http://members.tripod.com/~TyroneZero/drstrangelove.gif");
?>
Expected result:
----------------
Creates a GD image
Actual result:
--------------
Infinite Loop. Maxes out processor. Causes operating system to stall.
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Nov 29 17:00:01 2025 UTC |
I have reproduced this bug using php -r "imagecreatefromgif('http://members.tripod.com/~TyroneZero/drstrangelove.gif');" on both windows xp in PHP 5.0.0rc2 and linux with 4.3.6 (both command line). The above command causes it to hang. Tracing through the code using a debugger it does look a lot like an infinate loop, though it could just be a really long one. I believe the infinate loop starts at line 155 in gd_gif_in.c at for (;;) { - I think it may just not be reaching an exit condition. I may investigate more later. Very strangely, if I download the gif and run the same command without going to the site at runtime, there is no such problem. Irid.imagecreatefromgif("img.gif"); Child process of Apache usage 95% CPU and infinite loop The img.gif is corrupt