[prev in list] [next in list] [prev in thread] [next in thread] 

List:       wine-devel
Subject:    Re: kernel32: Implement ReplaceFileA/ReplaceFileW
From:       Felix Nawothnig <flexo () holycrap ! org>
Date:       2007-02-28 18:28:04
Message-ID: 45E5C9B4.4010707 () holycrap ! org
[Download RAW message or body]

Erich Hoover wrote:
>>>> The "right" way would probably to do the copying yourself by
>>>> read/write.. but I dunno.
>>> Except that it would ignore the permissions issues that have already
>>> been coded into the copy routines (and any updates that may eventually
>> No, CreateFile (and friends) does the permissions checks (which you
>> would still have to call).
> That was worded poorly, Copy/Move already handle copying file attributes 
> and I imagine would eventually implement copying the access control list 
> information.  Implementing ReplaceFile as calls to either Copy or Move 
> takes these issues into account.

I see your point. However, since the function you are implementing is in 
kernel32 anyway you could abstract it away and make both functions 
(CopyFile and ReplaceFile) call some internal function. That way you 
would get rid of the locking completly which is argueably somewhat ugly.

Felix



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic