From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7928 invoked from network); 12 May 2006 19:34:26 -0000 X-Spam-Checker-Version: SpamAssassin 3.1.1 (2006-03-10) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,FORGED_RCVD_HELO autolearn=ham version=3.1.1 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 12 May 2006 19:34:26 -0000 Received: (qmail 44530 invoked from network); 12 May 2006 19:34:18 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 12 May 2006 19:34:18 -0000 Received: (qmail 3636 invoked by alias); 12 May 2006 19:34:12 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 10260 Received: (qmail 3627 invoked from network); 12 May 2006 19:34:11 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 12 May 2006 19:34:11 -0000 Received: (qmail 43512 invoked from network); 12 May 2006 19:34:11 -0000 Received: from mail.starnix.com (24.215.7.100) by a.mx.sunsite.dk with SMTP; 12 May 2006 19:34:08 -0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by mail.starnix.com (Postfix) with ESMTP id 3EBBC4C2DB; Fri, 12 May 2006 15:34:06 -0400 (EDT) Received: from newsol.starnix.com (unknown [209.250.156.214]) by mail.starnix.com (Postfix) with ESMTP id DCAA84C2CB; Fri, 12 May 2006 15:34:02 -0400 (EDT) Received: by newsol.starnix.com (Postfix, from userid 510) id 2565348DF4; Fri, 12 May 2006 15:40:31 -0400 (EDT) Sender: tim@starnix.com From: Tim Writer To: Vincent Lefevre Cc: zsh-users@sunsite.dk Subject: Re: File locking within zsh? References: <87r7324zyh.fsf@asfast.com> <009101c673f7$06b3f090$6500000a@venti> <20060510171305.GA4116@prunille.vinc17.org> <009d01c67511$f91c8ed0$6500000a@venti> <20060512075401.GN4116@prunille.vinc17.org> Date: 12 May 2006 15:40:30 -0400 In-Reply-To: <20060512075401.GN4116@prunille.vinc17.org> Message-ID: User-Agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.4 (Common Lisp) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Virus-Scanned: by starnix.com Vincent Lefevre writes: > On 2006-05-11 11:45:21 -0400, Brian K. White wrote: > > > > ----- Original Message ----- > > From: "Vincent Lefevre" > > To: > > Sent: Wednesday, May 10, 2006 1:13 PM > > Subject: Re: File locking within zsh? > > > > > > >On 2006-05-10 01:59:57 -0400, Brian K. White wrote: > > >>Is that better or worse, and why, than umask 222 ; >file ? > > > > > >Are you sure that this is guaranteed to work with any NFS server? > > > > Not at all sure, never having tried on any nfs mount. > > So, it's probably better to use the symbolic link solution (ln -s), > which is guaranteed to be atomic, even on NFS. This is the solution > chosen by Firefox: https://bugzilla.mozilla.org/show_bug.cgi?id=76431 The solution was a hard link solution. I'm not sure that the symlink() system call is guaranteed to be atomic but link() is. -- tim writer starnix inc. 647.722.5301 toronto, ontario, canada http://www.starnix.com professional linux services & products