You are here: GD fns and memory leak « PHP Programming Language « IT news, forums, messages
GD fns and memory leak

Posted by fredforsyth.nospam@gmail.nospam.com on 12/22/05 12:02

I have a class for manipulating images, making thumbnails etc. When it
runs
under Apache, I find that each process is using up about 50M more than
when
it started.

I have three lines of code that show a similar problem:

$imNew = ImageCreateTrueColor(3000,2000);
ImageJPEG($imNew, '', 75);
ImageDestroy($imNew);

Without the ImageJPEG line, a newly created Apache process goes up by a
few
100K, which I can understand. Add in the ImageJPEG line and it goes up
about
30M. Surely the memory should be released when the image resource is
destroyed.

I have Apache 2.2.0 and PHP 4.4.1 running under Apache. Has anyone else
seen
this?? (It also occurs under Apache 2.0.54 and PHP 4.4.0)

Thanks in advance
Fred Forsyth
(remove .nospam to reply by email)

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация