This is the mail archive of the cygwin-patches@sourceware.cygnus.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: [RFA]: patch to 'rename', was Re: Wierd patch problem + simple fix


On Mon, May 22, 2000 at 11:35:54AM +0200, Corinna Vinschen wrote:
>Chris Faylor wrote:
>> 
>> On Sun, May 21, 2000 at 02:57:25PM +0200, Corinna Vinschen wrote:
>> >I'm completely unable to reproduce that problem...
>> >
>> >...as far as the $TMP directory is on the same drive
>> >   as the patched file!
>> >[...]
>> But I really can't believe that this is a generic patch bug.
>> /tmp is often located on a different partition than a 'src'
>> directory and it is hard to believe that this could be broken
>> in patch.
>> 
>> Is it possible that some stat (st_dev maybe?) field has changed
>> recently?
>
>I have investigated that phenomenon and I found that
>`MoveFile' returns ERROR_FILE_EXISTS while our `rename'
>code checks only for ERROR_ALREADY_EXISTS. Perhaps the return
>code is OS dependent? I'm testing mainly on W2K.

Or this got dropped when I recently rewrote that function.  Please
check in the patch.  It looks good.

cgf

>ChangeLog:
>==========
>
>	* syscalls.cc (_rename): Additionally check for ERROR_FILE_EXISTS
>	if MoveFile fails.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]