summaryrefslogtreecommitdiffstats
path: root/src/corelib/io/qfilesystemengine_unix.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/corelib/io/qfilesystemengine_unix.cpp')
-rw-r--r--src/corelib/io/qfilesystemengine_unix.cpp21
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