summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/corelib/io/qtemporaryfile.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/corelib/io/qtemporaryfile.cpp b/src/corelib/io/qtemporaryfile.cpp
index 6a9125c..b0809c6 100644
--- a/src/corelib/io/qtemporaryfile.cpp
+++ b/src/corelib/io/qtemporaryfile.cpp
@@ -364,9 +364,11 @@ bool QTemporaryFileEngine::remove()
// Since the QTemporaryFileEngine::close() does not really close the file,
// we must explicitly call QFSFileEngine::close() before we remove it.
QFSFileEngine::close();
- bool removed = QFSFileEngine::remove();
- d->filePath.clear();
- return removed;
+ if (QFSFileEngine::remove()) {
+ d->filePath.clear();
+ return true;
+ }
+ return false;
}
bool QTemporaryFileEngine::close()