From: "Matthew Smith" Newsgroups: comp.os.msdos.djgpp Subject: Re: files not closed after GPF Date: Sun, 5 Aug 2001 17:45:05 +0100 Lines: 21 Message-ID: <9kjsnd$ian$1@newsg3.svr.pol.co.uk> References: <20010805030625 DOT 08871 DOT 00002852 AT ng-fr1 DOT aol DOT com> NNTP-Posting-Host: modem-841.arcanine.dialup.pol.co.uk X-Trace: newsg3.svr.pol.co.uk 997029421 18775 217.135.19.73 (5 Aug 2001 16:37:01 GMT) NNTP-Posting-Date: 5 Aug 2001 16:37:01 GMT X-Complaints-To: abuse AT theplanet DOT net X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.50.4522.1200 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com > > Is it a bug ? I think you are doing about as well as can be expected, only losing one line line that. crashing with files open can actually wipe your whole file system if you are exceptionally unlucky. If your program was opening the file itself, it could adopt an "open,append,close quickly" strategy but redirecting the output makes your shell handle this. You could try outputting a few line feeds after critical information to flush the shell's buffer to disk. Matt