Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/18/84 (Fortune 01.1b1); site graffiti.UUCP Path: utzoo!watmath!clyde!burl!ulysses!allegra!mit-eddie!think!harvard!seismo!ut-sally!ut-ngp!shell!graffiti!peter From: peter@graffiti.UUCP (Peter da Silva) Newsgroups: net.unix-wizards Subject: Re: Another reason why a few sources should come with binary licenses Message-ID: <182@graffiti.UUCP> Date: Tue, 3-Sep-85 18:07:50 EDT Article-I.D.: graffiti.182 Posted: Tue Sep 3 18:07:50 1985 Date-Received: Tue, 10-Sep-85 03:40:46 EDT References: <1149@brl-tgr.ARPA> Organization: The Power Elite, Houston, TX Lines: 21 > a device?) with some special rules (delete on last close, no name in ^^^^^^^^^^^^^^^^^^^^ ^^^^^^^^^^ > the visible file space except to root etc.) Of course any design should ^^^^^^^^^^^^^^^^^^^^^^ > be ignorable (transparently work the old way at sites that don't need it, > like my UNIX/PC.) easy, do this when you make temporary files: ...make temp file name somehow (mktmp, maketmp, whatever it's called this week)... if(!(fp = fopen(file, mode))) { ...error processing... } unlink(file); An unlinked file is not actually thrown away until the last close. Viola. You get delete on last close & invisibility. Not that this is really important since most everyone keeps their files open and thus deleting them (rm /tmp/* was one problem suggested) wouldn't make much difference. For security just make your tmp file 0600 mode.