aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/System/Win32/Path.inc2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/System/Win32/Path.inc b/lib/System/Win32/Path.inc
index 8f3ceebb28..27baf82756 100644
--- a/lib/System/Win32/Path.inc
+++ b/lib/System/Win32/Path.inc
@@ -682,7 +682,7 @@ bool Path::getMagicNumber(std::string& Magic, unsigned len) const {
bool
Path::renamePathOnDisk(const Path& newName) {
- if (!MoveFile(path.c_str(), newName.c_str()))
+ if (!MoveFileEx(path.c_str(), newName.c_str(), MOVEFILE_REPLACE_EXISTING))
ThrowError("Can't move '" + path +
"' to '" + newName.path + "': ");
return true;