From: Alain Magloire Message-Id: <199904260237.WAA18935@mccoy2.ECE.McGill.CA> Subject: Re: A workaround for Unix-style temporary files To: djgpp-workers AT delorie DOT com Date: Sun, 25 Apr 1999 22:37:18 -0400 (EDT) In-Reply-To: <3723C1B9.B7EF27@cartsys.com> from "Nate Eldredge" at Apr 25, 99 06:30:33 pm X-Mailer: ELM [version 2.4 PL25] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Reply-To: djgpp-workers AT delorie DOT com X-Mailing-List: djgpp-workers AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk Bonjour > > Nevertheless, I still think the proposed "remove temp files on SIGSEGV" > is a bad idea. It's overly complex, and the payoff is minimal. > -- Two things come to mind. Again I'm not sure about DOS. - SIGSEGV is not the only sig that can terminate a process/program if not catch, SIGHUP, SIGPIPE, SIGABRT etc ... will terminate the process also. - Is the file still in the namespace after unlink() ? - On DOS, when the program terminates, is close() call on the file descriptors ? Many Un*x programmers(Yes, guilty) have the bad habit of not explicitly closing the file descritors. On termination of the process the kernel will release any resources hold by the process .i.e calling close on all descriptors. Maybe the unlink() or the _opentmp() emulation should register something with atexit() to make sure that close() is call. -- au revoir, alain ---- Aussi haut que l'on soit assis, on est toujours assis que sur son cul !!!