diff options
author | Liang Qi <liang.qi@qt.io> | 2017-04-20 11:19:14 +0200 |
---|---|---|
committer | Liang Qi <liang.qi@qt.io> | 2017-04-20 12:31:27 +0200 |
commit | 7950b6b283549c98f1e0f981c84b68071a13b616 (patch) | |
tree | cf7281872045ebd57c68e10064ff0f400084aa13 /src/corelib/io/qfilesystemengine_unix.cpp | |
parent | 58d2927861d3e57cac4f6db599e209d2bfb17a2c (diff) | |
parent | 0794d61c822585530243f638687b8a75f0a15d0c (diff) |
Merge remote-tracking branch 'origin/5.9' into dev
Conflicts:
src/corelib/tools/qbytearray.h
src/corelib/tools/qdatetime.h
src/corelib/tools/qstring.h
src/corelib/tools/qversionnumber.h
src/plugins/platforms/android/qandroidplatformintegration.cpp
tests/auto/corelib/tools/qhashfunctions/tst_qhashfunctions.cpp
Change-Id: Iefd92a435e687a76cd593099e40d9a9620a1454d
Diffstat (limited to 'src/corelib/io/qfilesystemengine_unix.cpp')
-rw-r--r-- | src/corelib/io/qfilesystemengine_unix.cpp | 21 |
1 files changed, 2 insertions, 19 deletions
diff --git a/src/corelib/io/qfilesystemengine_unix.cpp b/src/corelib/io/qfilesystemengine_unix.cpp index b8dca93f61..929db259ec 100644 --- a/src/corelib/io/qfilesystemengine_unix.cpp +++ b/src/corelib/io/qfilesystemengine_unix.cpp @@ -1,5 +1,6 @@ /**************************************************************************** ** +** Copyright (C) 2017 Intel Corporation. ** Copyright (C) 2016 The Qt Company Ltd. ** Copyright (C) 2013 Samuel Gaist <samuel.gaist@edeltech.ch> ** Contact: https://www.qt.io/licensing/ @@ -607,25 +608,7 @@ bool QFileSystemEngine::createDirectory(const QFileSystemEntry &entry, bool crea if (!createParents) return false; - // we need the cleaned path in order to create the parents - // and we save errno just in case encodeName needs to load codecs - int savedErrno = errno; - bool pathChanged; - { - QString cleanName = QDir::cleanPath(dirName); - - // Check if the cleaned name is the same or not. If we were given a - // path with resolvable "../" sections, cleanPath will remove them, but - // this may change the target dir if one of those segments was a - // symlink. This operation depends on cleanPath's optimization of - // returning the original string if it didn't modify anything. - pathChanged = !dirName.isSharedWith(cleanName); - if (pathChanged) - nativeName = QFile::encodeName(cleanName); - } - - errno = savedErrno; - return createDirectoryWithParents(nativeName, pathChanged); + return createDirectoryWithParents(nativeName, false); } //static |