Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: File locking within zsh?



Vincent Lefevre <vincent@xxxxxxxxxx> writes:

> On 2006-05-11 11:45:21 -0400, Brian K. White wrote:
> > 
> > ----- Original Message ----- 
> > From: "Vincent Lefevre" <vincent@xxxxxxxxxx>
> > To: <zsh-users@xxxxxxxxxx>
> > 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 <tim@xxxxxxxxxxx>                                  starnix inc.
647.722.5301                                      toronto, ontario, canada
http://www.starnix.com              professional linux services & products



Messages sorted by: Reverse Date, Date, Thread, Author