Memory Leaks/Crash bugs...
Sean Gillies
sgillies at FRII.COM
Tue Mar 7 03:24:19 EST 2006
On Mar 7, 2006, at 12:24 AM, Ned Harding wrote:
> 1st - Just an FYI - I fixed a major crash bug in the label cache when
> you have LOTS of objects. I'll get Jani to review and commit for me
> when he has some time.
>
> 2nd - memory leaks
>
> Again with LOTS (20,000+) of label items I am getting a LOT of memory
> leaks with the following stack (This is MapServer 4.6 code still)
> s:\3rdparty\gfx\freetype\src\base\ftsystem.c (109): ft_realloc
> s:\3rdparty\gfx\freetype\src\base\ftutil.c (137): FT_Realloc
> s:\3rdparty\gfx\freetype\src\base\ftobjs.c (2356): FT_CMap_New
> s:\3rdparty\gfx\freetype\src\sfnt\ttcmap.c (2179):
> tt_face_build_cmaps
> s:\3rdparty\gfx\freetype\src\sfnt\sfobjs.c (609): sfnt_load_face
> s:\3rdparty\gfx\freetype\src\truetype\ttobjs.c (209): tt_face_init
> s:\3rdparty\gfx\freetype\src\base\ftobjs.c (931): open_face
> s:\3rdparty\gfx\freetype\src\base\ftobjs.c (1635): FT_Open_Face
> s:\3rdparty\gfx\freetype\src\base\ftobjs.c (987): FT_New_Face
> s:\3rdparty\gfx\gd\gdft.c (473): fontFetch
> s:\3rdparty\gfx\gd\gdcache.c (124): gdCacheGet
> s:\3rdparty\gfx\gd\gdft.c (898): gdImageStringFTEx
> s:\3rdparty\gfx\gd\gdft.c (804): gdImageStringFT
> s:\3rdparty\gis\mapserver\maplabel.c (314): msGetLabelSize
> s:\3rdparty\gis\mapserver\mapgd.c (2870): msDrawLabelCacheGD
> s:\3rdparty\gis\mapserver\mapdraw.c (1897): msDrawLabelCache
> s:\3rdparty\gis\mapserver\mapdraw.c (542): msDrawMap
>
> Anyone know about this already? If not I'll spend a little time
> digging
> in to it.
>
> I am guessing that we are the only people who have embedded MapServer
> into desktop products and allowing users to throw crazy/bad data at
> it?
>
Ned,
Historically, MapServer is a fire and forget CGI application, with
not a lot of attention paid to memory management. It used to spring
leaks all over the place when it got into an error state. We fixed a
bunch of these bugs back in 4.4, but clearly we're not done yet.
If it makes you feel less lonely, I'm using MapServer within long-
running web applications, and I'm very interesting in helping to
squash this class of bugs. Feel free to cc me on anything you enter
in Bugzilla.
cheers,
Sean
---
Sean Gillies
sgillies frii com
http://zcologia.com
More information about the mapserver-dev
mailing list