summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormihai_stan <devnull@localhost>2015-02-05 15:52:50 +0200
committermihai_stan <devnull@localhost>2015-02-05 15:52:50 +0200
commitf2cde1f92acf660c178a17f7c774b4061e7771b8 (patch)
tree0c21a54cf923047533c3007a7cab3ff562981f02
parent2e1f5afab2497baf2a9e1fe47fed62482da3cfcc (diff)
downloadpylint-f2cde1f92acf660c178a17f7c774b4061e7771b8.tar.gz
Treat nulls as separators
-rw-r--r--checkers/spelling.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/checkers/spelling.py b/checkers/spelling.py
index 6cc604a..c716ff2 100644
--- a/checkers/spelling.py
+++ b/checkers/spelling.py
@@ -131,6 +131,8 @@ class SpellingChecker(BaseTokenChecker):
line2 = re.sub("([^a-zA-Z]|^)'", " ", line2)
# Replace punctuation signs with space e.g. and/or -> and or
line2 = self.punctuation_regex.sub(' ', line2)
+ # Replace null bytes with space
+ line2 = line2.replace('\x00', ' ')
words = []
for word in line2.split():