From: mankaho at lskcf5d dot net Operating system: Linux Mandrake PHP version: 4.3.4 PHP Bug Type: GD related Bug description: Problem with GD in php
Description: ------------ I use a GD in PHP: PHP Version 4.3.3 I get an error with can't allocate memory .... PHPconfig: http://expt.lskc.edu.hk/~l99534/info.php Reproduce code: --------------- <? header("Content-type: image/jpeg"); $im_in = imagecreatefromjpeg("1.jpg"); $im_out = imagecreatetruecolor(1024,768); imagecopyresized($im_out,$im_in,0,0,0,0,800,600,1024,768); imagejpeg($im_out); imagedestory($im_out); ?> Expected result: ---------------- I smaller photo will be generated.. on web browser Actual result: -------------- Fatal error: Allowed memory size of 8388608 bytes exhausted at (null):0 (tried to allocate 4096 bytes) in /var/www/html/2003/5d/test/test.php on line 7 -- Edit bug report at http://bugs.php.net/?id=27112&edit=1 -- Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=27112&r=trysnapshot4 Try a CVS snapshot (php5): http://bugs.php.net/fix.php?id=27112&r=trysnapshot5 Fixed in CVS: http://bugs.php.net/fix.php?id=27112&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=27112&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=27112&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=27112&r=needscript Try newer version: http://bugs.php.net/fix.php?id=27112&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=27112&r=support Expected behavior: http://bugs.php.net/fix.php?id=27112&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=27112&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=27112&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=27112&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=27112&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=27112&r=dst IIS Stability: http://bugs.php.net/fix.php?id=27112&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=27112&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=27112&r=float
