From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,9960fa51a4a478af X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-02-11 10:56:07 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!newsfeeds.belnet.be!news.belnet.be!fr.usenet-edu.net!usenet-edu.net!enst!enst.fr!not-for-mail From: Samuel Tardieu Newsgroups: comp.lang.ada Subject: Re: ACT announces availability of GNAT 3.14p Date: Mon, 11 Feb 2002 19:55:27 +0100 Organization: RFC 1149 (see http://www.rfc1149.net/) Sender: comp.lang.ada-admin@ada.eu.org Message-ID: References: <5ee5b646.0201301849.4e951bcb@posting.google.com> <5ee5b646.0202071709.11b3f88c@posting.google.com> <87ofixit6v.fsf@deneb.enyo.de> <5ee5b646.0202101038.68b3b71f@posting.google.com> <87n0yhf8e1.fsf@deneb.enyo.de> <5ee5b646.0202101355.2c8d7ebb@posting.google.com> <87g049f0wb.fsf@deneb.enyo.de> <5ee5b646.0202110436.6b5825e0@posting.google.com> Reply-To: comp.lang.ada@ada.eu.org NNTP-Posting-Host: marvin.enst.fr Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit X-Trace: avanie.enst.fr 1013453764 11007 137.194.161.2 (11 Feb 2002 18:56:04 GMT) X-Complaints-To: usenet@enst.fr NNTP-Posting-Date: Mon, 11 Feb 2002 18:56:04 +0000 (UTC) Return-Path: Content-Disposition: inline In-Reply-To: <5ee5b646.0202110436.6b5825e0@posting.google.com> User-Agent: Mutt/1.3.27i Precedence: special-delivery X-WWW: http://www.rfc1149.net/sam X-Mail-Processing: Sam's procmail tools X-ICQ: 21547599 X-Sam-Laptop: yes Errors-To: comp.lang.ada-admin@ada.eu.org X-BeenThere: comp.lang.ada@ada.eu.org X-Mailman-Version: 2.0.8 X-Reply-To: Samuel Tardieu List-Help: List-Post: List-Subscribe: , List-Id: comp.lang.ada mail<->news gateway List-Unsubscribe: , Errors-To: comp.lang.ada-admin@ada.eu.org X-BeenThere: comp.lang.ada@ada.eu.org Xref: archiver1.google.com comp.lang.ada:19878 Date: 2002-02-11T19:55:27+01:00 On 11/02, Robert Dewar wrote: | You seem to be arguing for not using /TMP for temporary | files ever, but that seems the wrong choice to us in a | Unix environment. Really you are arguing for removing this | feature from Unix entirely. OK, but that's an argument to | be carried on elsewhere, the policy of GNAT is to blend | harmoniously into the host operating system. If you manage | to convince Unix to remove the "dangerous" use of /TMP, then GNAT will | be happy to conform :-) /tmp is not unsafe, mktemp() is. On many systems, there exists another function called mkstemp() which returns an *open* file instead of a file name. Here is an excerpt of the FreeBSD man page: The mkstemp() function makes the same replacement to the template and creates the template file, mode 0600, returning a file descriptor opened for reading and writing. This avoids the race between testing for a file's existence and opening it for use. Using mkstemp() does remove the security hole. In fact, some linkers generate a warning if mktemp() is used to remind programmers that there are other ways to do that.