diff options
author | Nick Mathewson <nickm@torproject.org> | 2019-08-05 17:31:49 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2019-08-05 17:48:06 -0400 |
commit | 2a3c727dfed7465090c2b9bae2f5ac88b3c6dca0 (patch) | |
tree | 36dd005938c308a670f8a72b3247ba07145f0f2c /scripts/maint/practracker/practracker.py | |
parent | 6b26281b50f25f0175f3ba801951324a30ba7a32 (diff) | |
download | tor-2a3c727dfed7465090c2b9bae2f5ac88b3c6dca0.tar.gz tor-2a3c727dfed7465090c2b9bae2f5ac88b3c6dca0.zip |
Make includes interface more like the rest of practracker
Everything else assumes that somebody else will open the file for it.
Diffstat (limited to 'scripts/maint/practracker/practracker.py')
-rwxr-xr-x | scripts/maint/practracker/practracker.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/maint/practracker/practracker.py b/scripts/maint/practracker/practracker.py index 66ebb1277d..20c8bb5b4e 100755 --- a/scripts/maint/practracker/practracker.py +++ b/scripts/maint/practracker/practracker.py @@ -117,8 +117,10 @@ def consider_metrics_for_file(fname, f): for item in consider_function_size(fname, f): yield item + # Check for "upward" includes + f.seek(0) n = 0 - for item in includes.consider_include_rules(real_fname): + for item in includes.consider_include_rules(real_fname, f): n += 1 if n: yield problem.DependencyViolationItem(fname, n) |