From f4a8c4590e9257061da6832ae00c921b9d012e86 Mon Sep 17 00:00:00 2001 From: hjk Date: Mon, 31 May 2021 16:24:51 +0200 Subject: [PATCH] ProjectExplorer: Fix ProcessParameters::effectiveWorkingDirectory() ... for remote setups: QDir::cleanPath() must not be used on a fully stringified FilePath, as this also collapses the double slashs in the :// separator. Change-Id: I186328ecfc33665c50eda4efebe5d7a4cc3e4917 Reviewed-by: Christian Kandeler --- src/plugins/projectexplorer/processparameters.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/plugins/projectexplorer/processparameters.cpp b/src/plugins/projectexplorer/processparameters.cpp index fdec5291db8..a91f01264f6 100644 --- a/src/plugins/projectexplorer/processparameters.cpp +++ b/src/plugins/projectexplorer/processparameters.cpp @@ -100,11 +100,11 @@ void ProcessParameters::setWorkingDirectory(const FilePath &workingDirectory) FilePath ProcessParameters::effectiveWorkingDirectory() const { if (m_effectiveWorkingDirectory.isEmpty()) { - QString wds = m_workingDirectory.toString(); + m_effectiveWorkingDirectory = m_workingDirectory; + QString path = m_workingDirectory.path(); if (m_macroExpander) - wds = m_macroExpander->expand(wds); - m_effectiveWorkingDirectory - = FilePath::fromString(QDir::cleanPath(m_environment.expandVariables(wds))); + path = m_macroExpander->expand(path); + m_effectiveWorkingDirectory.setPath(QDir::cleanPath(m_environment.expandVariables(path))); } return m_effectiveWorkingDirectory; }