diff --git a/src/core/io/qfilesystemengine_unix.cpp b/src/core/io/qfilesystemengine_unix.cpp index 8f3b6a4e5..c3c36a576 100644 --- a/src/core/io/qfilesystemengine_unix.cpp +++ b/src/core/io/qfilesystemengine_unix.cpp @@ -397,8 +397,8 @@ bool QFileSystemEngine::copyFile(const QFileSystemEntry &source, const QFileSyst const int targetfd = QT_CREAT(target.nativeFilePath().constData(), st.st_mode); if (targetfd == -1) { - ::close(sourcefd); error = QSystemError(errno, QSystemError::StandardLibraryError); + ::close(sourcefd); return false; }