From f07841bc7c621d3bca01c4f2dc11cf62c11b30d5 Mon Sep 17 00:00:00 2001 From: Andy Shaw Date: Fri, 21 Feb 2014 15:21:24 +0100 Subject: Revert path() behavior to not expand a current path on a drive In the original change - cfb44c6528b2518274bf157388832d1d610ce0e4 - when querying for the path of a file that did not contain a slash after the drive indicator it would get the current path and return that as the path that the file resided on. However this meant that it would take the current path at that time which may not be the actual path that was expected. So it was decided that it should revert back to the original behavior which was to just return the drive letter followed by the colon which would thus indicate still that it represented whatever the current path was on that drive. Change-Id: Ic57ae9227882a66e9a4c4d6537d7f2cae829165a Reviewed-by: Thiago Macieira Reviewed-by: Oswald Buddenhagen --- src/corelib/io/qfilesystementry.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/corelib/io/qfilesystementry.cpp') diff --git a/src/corelib/io/qfilesystementry.cpp b/src/corelib/io/qfilesystementry.cpp index 42a724670e..5365ca9bcc 100644 --- a/src/corelib/io/qfilesystementry.cpp +++ b/src/corelib/io/qfilesystementry.cpp @@ -195,7 +195,7 @@ QString QFileSystemEntry::path() const if (m_lastSeparator == -1) { #if defined(Q_OS_WIN) if (m_filePath.length() >= 2 && m_filePath.at(1) == QLatin1Char(':')) - return QFSFileEngine::currentPath(m_filePath.left(2)); + return m_filePath.left(2); #endif return QString(QLatin1Char('.')); } -- cgit v1.2.3