www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/1999/04/22/05:02:50

Date: Thu, 22 Apr 1999 12:00:05 +0300 (IDT)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
X-Sender: eliz AT is
To: "Mark E." <snowball3 AT usa DOT net>
cc: djgpp-workers AT delorie DOT com
Subject: Re: A workaround for Unix-style temporary files
In-Reply-To: <199904210513.FAA31728@out1.ibm.net>
Message-ID: <Pine.SUN.3.91.990422115946.15748V-100000@is>
MIME-Version: 1.0
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

On Wed, 21 Apr 1999, Mark E. wrote:

> Wanting to have just one workaround, I created the _opentmp function. 
> It accepts a path and mode as arguments and returns a file handle on 
> success, a lot like open does. Except when close() is called, the file is 
> closed and then automatically deleted.

Personally, I think that solving this problem is only worth the hassle
if it can be solved transparently.  If a solution requires some
special code, like using O_TEMPORARY, then it will anyway require
DJGPP-specific code, and it isn't better than simply using `tmpfile'
(and taking the handle with `fileno', if it's required).

- Raw text -


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