websocket: fix compilation

pull/5801/head
Alexander Medvednikov 2020-07-11 12:41:37 +02:00
parent 649821be4c
commit 2e275731a3
1 changed files with 2 additions and 2 deletions

View File

@ -385,7 +385,7 @@ pub fn (mut ws Client) read() int {
frame_size = u64(header_len) + payload_len
if frame_size > initial_buffer {
l.d('reallocating: ${frame_size}')
data = v_realloc(data, frame_size)
data = v_realloc(data, u32(frame_size))
}
} else if frame.payload_len == u64(127) && bytes_read == u64(extended_payload64_end_byte) {
header_len += 8 // TODO Not sure...
@ -409,7 +409,7 @@ pub fn (mut ws Client) read() int {
frame_size = u64(header_len) + payload_len
if frame_size > initial_buffer {
l.d('reallocating: ${frame_size}')
data = v_realloc(data, frame_size)
data = v_realloc(data, u32(frame_size)) // TODO u64 => u32
}
}
}