readLp should warn on ignored exceptions

This commit is contained in:
Dmitriy Ryajov 2019-10-04 10:21:45 -06:00
parent a1c760127b
commit bb277d4b56
1 changed files with 1 additions and 1 deletions

View File

@ -102,7 +102,7 @@ proc readLp*(s: Connection): Future[seq[byte]] {.async, gcsafe.} =
if size > 0.uint: if size > 0.uint:
await s.readExactly(addr result[0], int(size)) await s.readExactly(addr result[0], int(size))
except LPStreamIncompleteError, LPStreamReadError: except LPStreamIncompleteError, LPStreamReadError:
error "readLp: could not read from remote", exception = getCurrentExceptionMsg() warn "readLp: could not read from remote, this is usually ok", exception = getCurrentExceptionMsg()
proc writeLp*(s: Connection, msg: string | seq[byte]): Future[void] {.gcsafe.} = proc writeLp*(s: Connection, msg: string | seq[byte]): Future[void] {.gcsafe.} =
## write lenght prefixed ## write lenght prefixed