aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorKevin O'Connor <kevin@koconnor.net>2018-07-27 12:55:41 -0400
committerKevin O'Connor <kevin@koconnor.net>2018-07-27 12:55:41 -0400
commitac5e207241f06156e6926c571558c4eff701cb18 (patch)
tree01d0b5852c57c539a0651b05bc1a1d677b66b1a4 /scripts
parent7c7de85f01417152a8dd8956f7804d7651ac0398 (diff)
downloadkutter-ac5e207241f06156e6926c571558c4eff701cb18.tar.gz
kutter-ac5e207241f06156e6926c571558c4eff701cb18.tar.xz
kutter-ac5e207241f06156e6926c571558c4eff701cb18.zip
check_whitespace: Minor simplification of control char check
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/check_whitespace.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/scripts/check_whitespace.py b/scripts/check_whitespace.py
index 13c4a3ed..3ee68693 100755
--- a/scripts/check_whitespace.py
+++ b/scripts/check_whitespace.py
@@ -36,10 +36,9 @@ def check_file(filename):
continue
# Check for control characters
for c in line:
- oc = ord(c)
- if oc < 32 or unicodedata.category(c).startswith('C'):
+ if unicodedata.category(c).startswith('C'):
char_name = repr(c)
- if oc == 9:
+ if c == '\t':
if os.path.basename(filename).lower() == 'makefile':
continue
char_name = 'tab'