[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [MiNT] FreeMiNT 1.18 release



>> 
>> Opened files can still be deleted or renamed, regardless of it being
>> locked or not - not sure if this is an issue or a new requirement.
>
>Renaming and deletion are operations on the directory where the file
>is, not on the file itself.  Locking a file affects only access to
>the file, not to the directory where it is.
>
>As long as process has an open handle to a file, it can access its
>data, regardless of where, whether or under what name the file resides
>in.
>


Yes, correct on both paragraph.

Renaming and deletion are operations on the directory. So these directory functions should not be allowed if a file is opened.
Currently if process A creates and writes a file A, there is no stopping for for user or another process B to rename or delete that file A.
If file A is deleted while process A is still writing, on the desktop you can see the file A changes in icon to a folder called A.

As long as process has an open handle to a file, it can access its data, regardless of where, whether or under what name the file resides in.
This is also a very true statement... like I mentioned above, even under what when name or no name, it is still able to write to it.
Amazingly after that, when closes the file, the file is no longer available or no longer seen in the folder.

These are funny behavior.....

rgds
WongCk