Prevent infinite recursion

In qtvirtualkeyboard/src/plugins/lipi-toolkit/3rdparty/lipi-toolkit/src/lipicommon.pri
we have TARGET = $$TARGET$$qtPlatformTargetSuffix which keeps on recursing.

Change-Id: Ia0e020c7258cd87bba9b9681ed7b4568e8f0c9c2
Reviewed-by: Qt CMake Build Bot
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
This commit is contained in:
Frederik Gladhorn 2019-10-31 16:52:23 +01:00
parent 48c56a992e
commit 5c6cf6692e

View File

@ -1111,6 +1111,9 @@ class Scope(object):
else: else:
replacement = self.get(match.group(1), inherit=True) replacement = self.get(match.group(1), inherit=True)
replacement_str = replacement[0] if replacement else "" replacement_str = replacement[0] if replacement else ""
if replacement_str == value:
# we have recursed
replacement_str = ""
result = result[: match.start()] + replacement_str + result[match.end() :] result = result[: match.start()] + replacement_str + result[match.end() :]
result = self._replace_env_var_value(result) result = self._replace_env_var_value(result)