From 903308e908633430f08a4e719c361e7279a982ef Mon Sep 17 00:00:00 2001 From: Nikita Baryshnikov Date: Fri, 25 Aug 2017 19:47:11 +0300 Subject: [PATCH] ProjectExplorer: check file renaming result Change-Id: I6872bc09f173e2af7a1ebc416d3d5ebcf9dea46a Reviewed-by: hjk --- src/plugins/projectexplorer/projectexplorer.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/plugins/projectexplorer/projectexplorer.cpp b/src/plugins/projectexplorer/projectexplorer.cpp index 1f45b23a542..726420e0bf2 100644 --- a/src/plugins/projectexplorer/projectexplorer.cpp +++ b/src/plugins/projectexplorer/projectexplorer.cpp @@ -3446,8 +3446,9 @@ void ProjectExplorerPlugin::renameFile(Node *node, const QString &newFilePath) .arg(projectFileName) .arg(QDir::toNativeSeparators(oldFilePath)) .arg(QDir::toNativeSeparators(newFilePath))); - if (res == QMessageBox::Yes) - FileUtils::renameFile(oldFilePath, newFilePath); + if (res == QMessageBox::Yes) { + QTC_CHECK(FileUtils::renameFile(oldFilePath, newFilePath)); + } }); return;