QSaveFile[win]: store error in nativeRenameOverwrite
We want to drop the fallback path, so we need to set an appropriate error when the native rename fails. Change-Id: I2746d79b9e5666f54c35ff7ac29a74191cf22740 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>bb10
parent
b26ec1f5dd
commit
5cf94bcc2f
|
|
@ -419,10 +419,10 @@ bool QFSFileEnginePrivate::nativeRenameOverwrite(const QString &newName)
|
|||
|
||||
bool res = SetFileInformationByHandle(fileHandle, FileRenameInfo, renameInfo,
|
||||
DWORD(renameDataSize));
|
||||
#if 0
|
||||
if (!res)
|
||||
qErrnoWarning("QFSFileEnginePrivate::nativeRenameOverwrite failed");
|
||||
#endif
|
||||
if (!res) {
|
||||
DWORD error = GetLastError();
|
||||
q_func()->setError(QFile::RenameError, qt_error_string(int(error)));
|
||||
}
|
||||
return res;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue