add eof and closed handling

This commit is contained in:
Dmitriy Ryajov 2020-05-11 22:27:54 -06:00
parent 62da2a05c3
commit 0f691cbafd
1 changed files with 3 additions and 0 deletions

View File

@ -167,6 +167,9 @@ method pushTo*(s: BufferStream, data: seq[byte]) {.base, async.} =
## is preserved.
##
if s.atEof:
raise newLPStreamEOFError()
if s.atEof:
raise newLPStreamEOFError()