From: "Damian Yerrick" Newsgroups: comp.os.msdos.djgpp Subject: Re: exit() makes my program crash!!!!! Date: Tue, 12 Oct 1999 11:46:59 -0500 Organization: Rose-Hulman Institute of Technology Lines: 33 Message-ID: <7tvopl$c74$1@solomon.cs.rose-hulman.edu> References: <19991012134544 DOT 29339 DOT rocketmail AT web107 DOT yahoomail DOT com> NNTP-Posting-Host: 137.112.111.210 X-Trace: solomon.cs.rose-hulman.edu 939746933 12516 137.112.111.210 (12 Oct 1999 16:48:53 GMT) X-Complaints-To: news AT cs DOT rose-hulman DOT edu NNTP-Posting-Date: 12 Oct 1999 16:48:53 GMT X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.00.2314.1300 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300 To: djgpp AT Delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Mohamed Saad wrote: > 1) a strange thing is happening! in a program of > mine, i made an Exit button! when it is pressed, it > simply calls... exit(1); > now... the problem is that when the button is > pressed, my whole program freezes!! it does not > respond to any thing! even ctrl-break does not work! > i tried to replace exit(1) with abort() and it > exited with no problem (but i can't use it! because it > outputs the stack contents and stuff!!) Post the source code for the smallest complete program that screws up like this. Then we can help you. If you really want our help, you might want to look at Read Me Third. http://www.rose-hulman.edu/~yerricde/minifaq.txt > now what does exit(1) do to freeze the program?? > > (Note: I have not hooked any interrupts!! the > program is runnin in 640*480*65k colors... in case > this helps!) Try setting the display mode back to text at the end of the program. If you're using Allegro, try calling allegro_exit() and then puts() Damian Yerrick http://come.to/yerrick