From:             [EMAIL PROTECTED]
Operating system: Windows 98 (1st ed)
PHP version:      4.2.1
PHP Bug Type:     GD related
Bug description:  Apache crashes when using imagecreatefromstring()

My machine is a Pentium 233MMX with 160 MB RAM.

I have tested this with:
 Apache 1.3.24 AND 2.0.36
 PHP 4.2.1 - php_gd.dll AND php_gd2.dll (only one at a time)

Here is the code being executed:
$query  = "SELECT image, width, height FROM site_image";
$query .= " WHERE image_id=\"".$image_id."\";";
$result = mysql_query($query, $linkid);
$rowarray = mysql_fetch_array($result, MYSQL_ASSOC);
$old_image = imagecreatefromstring($rowarray["image"]);

I know that it is the imagecreatefromstring() function causing the crash
because when I remove it, the code doesn't work, but it doesn't crash
either.

I get the error:
"This program has performed and illegal operation and will be shut down."

These are the details:
APACHE caused an invalid page fault in
module PHP_GD2.DLL at 0197:017c1317.
Registers:
EAX=05095000 CS=0197 EIP=017c1317 EFLGS=00010246
EBX=00000000 SS=019f ESP=0195f7e8 EBP=0195f7f8
ECX=00000000 DS=019f ESI=007a6b50 FS=8b27
EDX=ffffe2ee ES=019f EDI=00000001 GS=0000
Bytes at CS:EIP:
8a 08 89 4d fc 8b 55 f0 83 c2 01 89 55 f0 33 c0 
Stack dump:
05095000 ffffe2ee 006d78d0 00000000 0195f808 017c1dc9 0195f93c 000000da
0195f820 017d2b05 0195f93c 017d2f44 006d78b8 006d78d0 0195f834 017c05c6 
-- 
Edit bug report at http://bugs.php.net/?id=17528&edit=1
-- 
Fixed in CVS:        http://bugs.php.net/fix.php?id=17528&r=fixedcvs
Fixed in release:    http://bugs.php.net/fix.php?id=17528&r=alreadyfixed
Need backtrace:      http://bugs.php.net/fix.php?id=17528&r=needtrace
Try newer version:   http://bugs.php.net/fix.php?id=17528&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=17528&r=support
Expected behavior:   http://bugs.php.net/fix.php?id=17528&r=notwrong
Not enough info:     http://bugs.php.net/fix.php?id=17528&r=notenoughinfo
Submitted twice:     http://bugs.php.net/fix.php?id=17528&r=submittedtwice
register_globals:    http://bugs.php.net/fix.php?id=17528&r=globals

Reply via email to