From b7796bf309a6f174bd2ba23e5e1dc8fbacfead9e Mon Sep 17 00:00:00 2001 From: Tobias Hunger <tobias.hunger@nokia.com> Date: Mon, 8 Nov 2010 11:28:54 +0100 Subject: [PATCH] Make sure we do not get "//" in the QMake path Task-number: QTCREATORBUG-2990 --- src/libs/utils/buildablehelperlibrary.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/libs/utils/buildablehelperlibrary.cpp b/src/libs/utils/buildablehelperlibrary.cpp index 7b42a8d7792..ccaf9b1335e 100644 --- a/src/libs/utils/buildablehelperlibrary.cpp +++ b/src/libs/utils/buildablehelperlibrary.cpp @@ -48,8 +48,11 @@ QString BuildableHelperLibrary::findSystemQt(const Utils::Environment &env) { QStringList paths = env.path(); foreach (const QString &path, paths) { + QString prefix = path; + if (!prefix.endsWith(QLatin1Char('/'))) + prefix.append(QLatin1Char('/')); foreach (const QString &possibleCommand, possibleQMakeCommands()) { - const QFileInfo qmake(path + QLatin1Char('/') + possibleCommand); + const QFileInfo qmake(prefix + possibleCommand); if (qmake.exists()) { if (!qtVersionForQMake(qmake.absoluteFilePath()).isNull()) { return qmake.absoluteFilePath(); -- GitLab