X-Authentication-Warning: delorie.com: mail set sender to djgpp-workers-bounces using -f Sender: rich AT phekda DOT freeserve DOT co DOT uk Message-ID: <3FA5693D.C039DDB6@phekda.freeserve.co.uk> Date: Sun, 02 Nov 2003 20:29:49 +0000 From: Richard Dawe X-Mailer: Mozilla 4.77 [en] (X11; U; Linux 2.2.23 i586) X-Accept-Language: de,fr MIME-Version: 1.0 To: Eli Zaretskii CC: djgpp-workers AT delorie DOT com Subject: Re: locale fixes References: <3F9E3836 DOT 000008 DOT 02793 AT soapbox DOT yandex DOT ru> <3F9EC775 DOT 41795CD0 AT phekda DOT freeserve DOT co DOT uk> <3F9FD9C8 DOT 000003 DOT 05203 AT ariel DOT yandex DOT ru> <3FA164AB DOT EC4594A8 AT phekda DOT freeserve DOT co DOT uk> <2914-Thu30Oct2003223802+0200-eliz AT elta DOT co DOT il> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Reply-To: djgpp-workers AT delorie DOT com Hello. Eli Zaretskii wrote: > > > Date: Thu, 30 Oct 2003 19:21:15 +0000 > > From: Richard Dawe > > > > > I have no good idea how to check fix for the realloc() in regex. > > > I did it by the visual examination of code. > > > > I was thinking of something like this: > > > > Write some regression tests for regexps. (Actually, there are already > > some.) Modify realloc so that it fails randomly. Rebuild libc and test. > > Check that nothing bad happens. > > Can functions in malldbg.c help here? It looks like it can help detect buffer overruns. I couldn't see a way to make realloc fail 25% of the time, say. It would be nice to have something like this, to check that libc handles malloc/realloc failures gracefully. Maybe the memory allocation hooks could return an int, to indicate whether the operation should be allowed to take place. Or maybe that belongs in a new set of hooks - a memory allocation policy manager? Bye, Rich =] -- Richard Dawe [ http://www.phekda.freeserve.co.uk/richdawe/ ] "You can't evaluate a man by logic alone." -- McCoy, "I, Mudd", Star Trek