Windows: Work around misbehaved rename().
authorJohannes Sixt <johannes.sixt@telecom.at>
Fri, 7 Dec 2007 21:19:40 +0000 (22:19 +0100)
committerJohannes Sixt <johannes.sixt@telecom.at>
Mon, 23 Jun 2008 11:40:18 +0000 (13:40 +0200)
Windows's rename() is based on the MoveFile() API, which fails if the
destination exists. Here we work around the problem by using MoveFileEx().
Furthermore, the posixly correct error is returned if the destination is
a directory.

The implementation is still slightly incomplete, however, because of the
missing error code translation: We assume that the failure is due to
permissions.

Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at>
No differences found