diff options
author | Eike Ziller <eike.ziller@qt.io> | 2018-08-07 09:42:02 +0200 |
---|---|---|
committer | Eike Ziller <eike.ziller@qt.io> | 2018-08-07 09:42:02 +0200 |
commit | 847787f146b2583167f9d4bdbfb912c075b4af15 (patch) | |
tree | 822cac1939880b28b90ab78cf9c7aad8bccea6ce /src/libs/utils/environment.cpp | |
parent | 141f19a65283d3b2ac5677068cd858e1ace10623 (diff) | |
parent | ff10f8c3a58c2c57e221e294d5c4829c3fd05c15 (diff) |
Merge remote-tracking branch 'origin/4.7'
Conflicts:
src/plugins/debugger/debuggerruncontrol.cpp
Change-Id: I72882df605bc3fc8a8d20118fd4e49207ac92664
Diffstat (limited to 'src/libs/utils/environment.cpp')
-rw-r--r-- | src/libs/utils/environment.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/libs/utils/environment.cpp b/src/libs/utils/environment.cpp index d7eb1e7c1d..9b77a8b71e 100644 --- a/src/libs/utils/environment.cpp +++ b/src/libs/utils/environment.cpp @@ -49,8 +49,10 @@ public: toReplace.append(':'); toReplace.append(lib.path()); - if (ldLibraryPath.startsWith(toReplace)) - set("LD_LIBRARY_PATH", ldLibraryPath.remove(0, toReplace.length())); + if (ldLibraryPath.startsWith(toReplace + ':')) + set("LD_LIBRARY_PATH", ldLibraryPath.remove(0, toReplace.length() + 1)); + else if (ldLibraryPath == toReplace) + unset("LD_LIBRARY_PATH"); } } }; |