diff options
Diffstat (limited to '.arc-linters')
-rwxr-xr-x | .arc-linters/check-binaries.py | 4 | ||||
-rwxr-xr-x | .arc-linters/check-cpp.py | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/.arc-linters/check-binaries.py b/.arc-linters/check-binaries.py index 9125985489..85227eaa4e 100755 --- a/.arc-linters/check-binaries.py +++ b/.arc-linters/check-binaries.py @@ -9,8 +9,8 @@ import json path = sys.argv[1] warnings = [] if os.path.isfile(path): - with open(path) as f: - if '\0' in f.read(8000): + with open(path, 'rb') as f: + if b'\0' in f.read(8000): warning = { 'severity': 'warning', 'message': 'This file appears to be a binary file; does it really belong in the repository?' diff --git a/.arc-linters/check-cpp.py b/.arc-linters/check-cpp.py index 52961e6edd..f9d0552b00 100755 --- a/.arc-linters/check-cpp.py +++ b/.arc-linters/check-cpp.py @@ -25,9 +25,9 @@ logger.debug(sys.argv) path = sys.argv[1] warnings = [] -r = re.compile(r'ASSERT\s+\(') +r = re.compile(rb'ASSERT\s+\(') if os.path.isfile(path): - with open(path) as f: + with open(path, 'rb') as f: for lineno, line in enumerate(f): if r.search(line): warning = { |