summaryrefslogtreecommitdiffstats
path: root/src/corelib/io/qdir.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/corelib/io/qdir.cpp')
-rw-r--r--src/corelib/io/qdir.cpp11
1 files changed, 4 insertions, 7 deletions
diff --git a/src/corelib/io/qdir.cpp b/src/corelib/io/qdir.cpp
index b35cd2b..5ae54fc 100644
--- a/src/corelib/io/qdir.cpp
+++ b/src/corelib/io/qdir.cpp
@@ -1585,14 +1585,11 @@ bool QDir::makeAbsolute() // ### What do the return values signify?
if (QDir::isRelativePath(absolutePath))
return false;
- Q_D(QDir);
-
- d->path = absolutePath;
- d->initFileEngine();
- d->clearFileLists();
-
- if (!(d->fileEngine->fileFlags(QAbstractFileEngine::TypesMask) & QAbstractFileEngine::DirectoryType))
+ QDir dir(absolutePath);
+ if (!(dir.d_ptr.constData()->fileEngine->fileFlags(QAbstractFileEngine::TypesMask) & QAbstractFileEngine::DirectoryType))
return false;
+
+ *this = dir;
return true;
}