mirror of https://github.com/Desuuuu/klipper.git
console: Use regular str() types for commands on Python2
Avoid using unicode() types on Python2 as it can lead to subtle errors. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
parent
d6c3aaad8a
commit
7a6fd1a1aa
|
@ -187,7 +187,7 @@ class KeyboardReader:
|
||||||
return None
|
return None
|
||||||
return line
|
return line
|
||||||
def process_kbd(self, eventtime):
|
def process_kbd(self, eventtime):
|
||||||
self.data += os.read(self.fd, 4096).decode()
|
self.data += str(os.read(self.fd, 4096).decode())
|
||||||
|
|
||||||
kbdlines = self.data.split('\n')
|
kbdlines = self.data.split('\n')
|
||||||
for line in kbdlines[:-1]:
|
for line in kbdlines[:-1]:
|
||||||
|
|
Loading…
Reference in New Issue