www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2001/02/19/12:32:54

From: "Tim Van Holder" <tim DOT van DOT holder AT pandora DOT be>
To: <djgpp-workers AT delorie DOT com>
Subject: O_TEMPORARY and unlink()
Date: Mon, 19 Feb 2001 18:33:03 +0100
Message-ID: <CAEGKOHJKAAFPKOCLHDIKELJCAAA.tim.van.holder@pandora.be>
MIME-Version: 1.0
X-Priority: 3 (Normal)
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0)
Importance: Normal
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400
Reply-To: djgpp-workers AT delorie DOT com

Ran across this in the glibc documentation today:

     The `unlink' function deletes the file name FILENAME.  If this is
     a file's sole name, the file itself is also deleted.  (Actually,
     if any process has the file open when this happens, deletion is
     postponed until all processes have closed the file.)

Seems to me that this fits in nicely with the O_TEMPORARY support
(although well-behaved programs will usually close a file before
unlinking it).

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019