Skip to content
This repository has been archived by the owner on Oct 14, 2022. It is now read-only.

Commit

Permalink
tcp: eol check error
Browse files Browse the repository at this point in the history
  • Loading branch information
jordens committed Feb 3, 2020
1 parent e408b6a commit e843913
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion highfinesse_net/tcp.py
Expand Up @@ -33,7 +33,8 @@ def _writeline(self, cmd):

async def _readline(self):
r = await self._reader.readline()
assert r.endswith(self.eol_read)
if not r.endswith(self.eol_read):
raise ValueError("eol not found in response", r)
return r[:-len(self.eol_read)].decode()

async def _read(self, n):
Expand Down

0 comments on commit e843913

Please sign in to comment.