chiark
/
gitweb
/
~ian
/
hippotat.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
wip, fixes
[hippotat.git]
/
hippotat
/
__init__.py
diff --git
a/hippotat/__init__.py
b/hippotat/__init__.py
index 798f5d2bbce4f3f31a8eef9bbec3a83dcc7e250e..4cc9e70855bfb49f609d6695e85b5a07eb7c51aa 100644
(file)
--- a/
hippotat/__init__.py
+++ b/
hippotat/__init__.py
@@
-23,6
+23,7
@@
from configparser import NoOptionError
import collections
import time
import codecs
import collections
import time
import codecs
+import traceback
import re as regexp
import re as regexp
@@
-162,8
+163,9
@@
class SlipStreamDecoder():
def inputdata(self, data):
#print('SLIP-GOT ', repr(data))
def inputdata(self, data):
#print('SLIP-GOT ', repr(data))
- self._buffer += data
- packets = slip.decode(self._buffer)
+ data = self._buffer + data
+ self._buffer = b''
+ packets = slip.decode(data)
self._buffer = packets.pop()
for packet in packets:
self._maybe_packet(packet)
self._buffer = packets.pop()
for packet in packets:
self._maybe_packet(packet)