typos
This commit is contained in:
parent
27a7f8c948
commit
4df151a3a3
|
@ -57,7 +57,7 @@ proc writeMsg*(conn: Connection,
|
|||
let
|
||||
chunkSize = if left > MaxMsgSize: MaxMsgSize - 64 else: left
|
||||
chunk = if chunkSize > 0 : data[offset..(offset + chunkSize - 1)] else: data
|
||||
## write lenght prefixed
|
||||
## write length prefixed
|
||||
var buf = initVBuffer()
|
||||
buf.writePBVarint(id shl 3 or ord(msgType).uint64)
|
||||
buf.writePBVarint(chunkSize.uint64) # size should be always sent
|
||||
|
|
|
@ -44,7 +44,7 @@ proc writeLp*(s: StreamTransport, msg: string | seq[byte]): Future[int] {.gcsafe
|
|||
result = s.write(buf.buffer)
|
||||
|
||||
proc readLp*(s: StreamTransport): Future[seq[byte]] {.async, gcsafe.} =
|
||||
## read lenght prefixed msg
|
||||
## read length prefixed msg
|
||||
var
|
||||
size: uint
|
||||
length: int
|
||||
|
|
Loading…
Reference in New Issue