Subject: Re: odb_mkstemp's 0444 permission broke write/delete access on AFP

From: Matthieu Moy <[email-masked]>
Date: Mon, 16 Feb 2015 20:08:15 +0100

[ Please, don't top post on this list ]

Fairuzan Roslan <[email-masked]> writes:

> I don’t see the issue for the owner of his/her own file to have write
> access.

Object and pack files are not meant to be modified. Hence, they are
read-only so that an (accidental) attempt to modify them fails.

> Setting tmp idx & pack files to read-only even for the file owner is
> not a safety feature.

Yes it is. If you do not think so, then please give some arguments.

> You should at least give the user the option to set the permission in
> the config file and not hardcoded the permission in the binary.

This is the kind of thing I meant by "investigate alternate solutions".
I have no AFP share to test, so it would help if you answered the
question I asked in my previous message:

>> On Feb 17, 2015, at 2:23 AM, Matthieu Moy <[email-masked]> wrote:
>> 
>> Fairuzan Roslan <[email-masked]> writes:
>> 
>>> Hi,
>>> 
>>> Somehow the “int mode = 0444;” in odb_mkstemp (environment.c) are
>>> causing a lot of issues (unable to unlink/write/rename) to those
>>> people who use AFP shares.
>> 
>> Is it a problem when using Git (like "git gc" failing to remove old
>> packs), or when trying to remove files outside Git?

(BTW, why did you try to write/rename pack files?)

-- 
Matthieu Moy
http://www-verimag.imag.fr/~moy/