Gui: Check return value
Coverity issue 513113
This commit is contained in:
committed by
Benjamin Nauck
parent
44e15af433
commit
f534d47700
@@ -83,7 +83,9 @@ void AutoSaver::renameFile(QString dirName, QString file, QString tmpFile)
|
||||
<< " -> " << file.toUtf8().constData());
|
||||
QDir dir(dirName);
|
||||
dir.remove(file);
|
||||
dir.rename(tmpFile,file);
|
||||
if (!dir.rename(tmpFile,file)) {
|
||||
FC_ERR("Failed to rename autosave file " << tmpFile.toStdString() << " to " << file.toStdString() << "\n");
|
||||
}
|
||||
}
|
||||
|
||||
void AutoSaver::setTimeout(int ms)
|
||||
|
||||
Reference in New Issue
Block a user