Re: Why lock a file when reading?


Subject: Re: Why lock a file when reading?
From: wesley.craig@umich.edu
Date: Wed Mar 30 1994 - 14:23:06 EST


> From: kire@nada.kth.se (Jan-Erik M}ngs)
> To: netatalk-admins@umich.edu

> bg@nada.kth.se who has taken care of netatalk here sent me the
> following patch ("why lock a file while reading?"). Any comments, is
> this wrong?

Yes, it is wrong. You lock a file when reading to prevent others from
writing the file.

Since you're checking for errno == EACCESS, I assume that you're using
AFS -- AFS will return EACCESS when someone attempts to lock a file but
doesn't have the 'k' access bit.

:wes



This archive was generated by hypermail 2b28 : Sat Dec 18 1999 - 16:20:52 EST