mirror of
https://github.com/encounter/aurora.git
synced 2025-07-09 14:45:52 +00:00
Use MoveFileEx for Win32 file renaming
This commit is contained in:
parent
62be64f1aa
commit
24cf526773
@ -319,7 +319,7 @@ static inline int Rename(const SystemChar* oldpath, const SystemChar* newpath)
|
||||
{
|
||||
#if CARD_UCS2
|
||||
//return _wrename(oldpath, newpath);
|
||||
return ReplaceFileW(newpath, oldpath, nullptr, 0, nullptr, nullptr) == 0;
|
||||
return MoveFileExW(oldpath, newpath, MOVEFILE_REPLACE_EXISTING | MOVEFILE_WRITE_THROUGH) == 0;
|
||||
#else
|
||||
return rename(oldpath, newpath);
|
||||
#endif
|
||||
|
Loading…
x
Reference in New Issue
Block a user