1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

vlib/net: add buffered IO, x.net -> net (#6754)

This commit is contained in:
Emily Hudson
2020-11-15 20:54:47 +00:00
committed by GitHub
parent 20bec81678
commit cd2a2cef25
55 changed files with 741 additions and 1648 deletions

View File

@@ -111,7 +111,7 @@ fn (mut ws Client) read_handshake_str() ?string {
mut msg := [1024]byte{}
mut buffer := [1]byte{}
for total_bytes_read < 1024 {
bytes_read := ws.socket_read_into_ptr(byteptr(&buffer), 1) ?
bytes_read := ws.socket_read_ptr(byteptr(&buffer), 1) ?
if bytes_read == 0 {
return error_with_code('unexpected no response from handshake', 5)
}