summaryrefslogtreecommitdiff
path: root/src/plugins/projectexplorer
diff options
context:
space:
mode:
authorDavid Schulz <david.schulz@qt.io>2021-09-09 08:29:07 +0200
committerDavid Schulz <david.schulz@qt.io>2021-09-09 09:47:41 +0000
commitd5e0567f781c966552472f6956543053bc120be5 (patch)
tree7beef4c3421a3db7dc3dcafd96c398acd1ef8413 /src/plugins/projectexplorer
parent66b97761b6794025cf724cbb19105d919a6348a5 (diff)
downloadqt-creator-d5e0567f781c966552472f6956543053bc120be5.tar.gz
ProjectExplorer: prevent using QFileInfo on remote paths
Change-Id: Icf5dc9a80af69e8e1c3d733847e227486fa8c897 Reviewed-by: hjk <hjk@qt.io>
Diffstat (limited to 'src/plugins/projectexplorer')
-rw-r--r--src/plugins/projectexplorer/project.cpp2
-rw-r--r--src/plugins/projectexplorer/projectnodes.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/projectexplorer/project.cpp b/src/plugins/projectexplorer/project.cpp
index 4c71e965df..08e46dc11a 100644
--- a/src/plugins/projectexplorer/project.cpp
+++ b/src/plugins/projectexplorer/project.cpp
@@ -709,7 +709,7 @@ FilePath Project::projectDirectory(const FilePath &top)
{
if (top.isEmpty())
return FilePath();
- return FilePath::fromString(top.toFileInfo().absoluteDir().path());
+ return top.absolutePath();
}
void Project::changeRootProjectDirectory()
diff --git a/src/plugins/projectexplorer/projectnodes.cpp b/src/plugins/projectexplorer/projectnodes.cpp
index 69fcd50c1a..7b6866f92a 100644
--- a/src/plugins/projectexplorer/projectnodes.cpp
+++ b/src/plugins/projectexplorer/projectnodes.cpp
@@ -71,7 +71,7 @@ static FolderNode *recursiveFindOrCreateFolderNode(FolderNode *folder,
Utils::FilePath directoryWithoutPrefix;
bool isRelative = false;
- if (path.isEmpty() || path.toFileInfo().isRoot()) {
+ if (path.isEmpty() || path.toDir().isRoot()) {
directoryWithoutPrefix = directory;
isRelative = false;
} else {