Date: Wed, 1 Mar 2000 05:51:22 +0600 (LKT) From: Kalum Somaratna aka Grendel X-Sender: root AT darkstar DOT grendel DOT net To: djgpp AT delorie DOT com Subject: Re: Prevent crash on free() In-Reply-To: <89gd09$f0k$1@cubacola.tninet.se> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: djgpp AT delorie DOT com Errors-To: dj-admin AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk On Tue, 29 Feb 2000, Marcus wrote: > > Maybe you can answer this. Is it possible to do a catch a crash? :) > I mean, prevent the program from crashing. Instead raise an exception or > something like that. I think the SIGNAL handling mechanism would help you a lot here. Infact the crash dump that you see sometimes is printed by a handler which catches the SIGSEGV etc and handles it. The libc reference (info libc) has a large section called signal functions. The signal function itself contains a lot of info and I think it would be nice if you could check out the signal funcion in the djgpp libc reference. It most probably is what you are looking for. Grendel > > Hi, I'm a signature virus. plz set me as your signature and help me spread > :) This virus certainly seems very popular :-) only ~80 bytes too Hi, I'm a signature virus. plz set me as your signature and help me spread :)