mirror of
https://github.com/codex-storage/nim-libp2p.git
synced 2025-01-27 11:15:39 +00:00
should not handle transport exceptions
This commit is contained in:
parent
99869aa8b8
commit
dd3f85965b
@ -62,9 +62,9 @@ method readUntil*(s: ChronosStream,
|
|||||||
sep: seq[byte]): Future[int] {.async, gcsafe.} =
|
sep: seq[byte]): Future[int] {.async, gcsafe.} =
|
||||||
try:
|
try:
|
||||||
result = await s.reader.readUntil(pbytes, nbytes, sep)
|
result = await s.reader.readUntil(pbytes, nbytes, sep)
|
||||||
except TransportIncompleteError, AsyncStreamIncompleteError:
|
except AsyncStreamIncompleteError:
|
||||||
raise newLPStreamIncompleteError()
|
raise newLPStreamIncompleteError()
|
||||||
except TransportLimitError, AsyncStreamLimitError:
|
except AsyncStreamLimitError:
|
||||||
raise newLPStreamLimitError()
|
raise newLPStreamLimitError()
|
||||||
except LPStreamReadError as exc:
|
except LPStreamReadError as exc:
|
||||||
raise newLPStreamReadError(exc.par)
|
raise newLPStreamReadError(exc.par)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user