Skip to content

Commit

Permalink
Fix header unpacking slice.
Browse files Browse the repository at this point in the history
  • Loading branch information
christoph2 committed Dec 13, 2018
1 parent 613f8b2 commit 8ba2b7a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pyxcp/transport/eth.py
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,8 @@ def listen(self):
else:
try:
response, server = sock_recv(Eth.MAX_DATAGRAM_SIZE)
length, counter = HEADER_UNPACK(response)
response = response[HEADER_SIZE:]
length, counter = HEADER_UNPACK(response[: HEADER_SIZE])
response = response[HEADER_SIZE :]
except Exception as e:
self.logger.error(str(e))
continue
Expand Down

0 comments on commit 8ba2b7a

Please sign in to comment.