Re: PNGs causing core dumps


Subject: Re: PNGs causing core dumps
From: Dom Lachowicz (dominicl@seas.upenn.edu)
Date: Fri Jul 06 2001 - 10:58:23 CDT


Quoting Adrian Phillips <adrianp@powertech.no>:

>
> I've been trying to figure out why trying to insert a PNG into a
> document was causing core dumps, at work it sometimes worked but not
> at home.
>
> In xp/gr_Image.h the following member of GR_Image (note my C++
> knowledge is based upon hacking perl so I may well get my terminology
> wrong :-) has a rather restrictive size :-
>
> char m_szName[GR_IMAGE_MAX_NAME_LEN+1];
>
> with :-
>
> #define GR_IMAGE_MAX_NAME_LEN 63
>
> isn't this rather grotuesque ? I would have thought that at least
> PATH_MAX or whatever POSIX defines should be used at least for Unix ?
>
> Hmm, I just noticed that its setup if it doesn't exist for all
> platforms so it seems that PATH_MAX is the correct define to use.
>
> I wonder also if there are other places that have done similar things
> ? (grepping for NAME_LEN didn't find anything else)
>
> Any comments ?

I'll change this to use our UT_String class.

Dom



This archive was generated by hypermail 2b25 : Fri Jul 06 2001 - 10:58:25 CDT