[Gambas-user] How to lock a file

Rolf-Werner Eilert eilert-sprachen at ...221...
Wed Oct 8 17:31:45 CEST 2008


Doriano Blengino schrieb:
> Rolf-Werner Eilert ha scritto:
>> Alright, but it doesn't delete the lock-file with UNLOCK, and the 
>> lock-file has standard rights rw-r--r-- (644), so no other user than the 
>> one who has created it should be able to delete it. Up to now, I just 
>> tested it on my own account with a file from my own, but I would be 
>> surprised if this mechanism made an exception from such basic rules here.
>>   
> Be aware - to delete a file you don't need permission to write to it; 
> you need permission to write the directory where the file resides...
> 
> cheers,
> Doriano
> 

Oooops - yes :-) Of course, that would mean, the next process of another 
user could delete it and set a lock-file with this user's rights.

I tend to forget this...

Thank you

Rolf





More information about the User mailing list