diff options
author | Tom Rix <tom.rix@sony.com> | 2018-11-08 07:46:01 -0800 |
---|---|---|
committer | Kim Grasman <kim.grasman@gmail.com> | 2018-12-08 15:03:23 +0100 |
commit | 7d9e918de22efdfabc32763707cb230150fc0a26 (patch) | |
tree | 8e741e66fb5de715ec610bdd0720ae74bb95a332 | |
parent | 94f71b6b17b38f7931dd304eb93a80b669cec84a (diff) |
When include-what-you-use if found, return the real path
If iwyu_tool.py is call by a relative path, include-what-you-use will
also be called with a static, relative path. Which breaks once the
cwd changes. So force the tool path to be absolute.
-rwxr-xr-x | iwyu_tool.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/iwyu_tool.py b/iwyu_tool.py index dcb7396..bdada75 100755 --- a/iwyu_tool.py +++ b/iwyu_tool.py @@ -108,7 +108,7 @@ def find_include_what_you_use(): for dirpath in search_path: full = os.path.join(dirpath, executable_name) if os.path.isfile(full): - return full + return os.path.realpath(full) return None |