mirror of
https://github.com/curl/curl.git
synced 2026-08-24 13:03:35 +03:00
When curl_ws_start_frame() has been called, do not treat a 0
return value as an EOF. Continue reading frames. Merge client reader rewind/unpause callbacks into a single "cntrl" callback and define opcodes to trigger the rewind/unpause/eos clearing. Add pytest case test_20_09 for transmitting 0-length ws frames.
This commit is contained in:
parent
476076e6c2
commit
caa37c390b
9 changed files with 188 additions and 107 deletions
|
|
@ -46,6 +46,14 @@ the data belonging to the frame.
|
|||
The function fails, if a previous frame has not been completely
|
||||
read yet. Also it fails in *CURLWS_RAW_MODE*.
|
||||
|
||||
The read function in libcurl usually treats a return value of 0
|
||||
as the end of file indication and stops any further reads. This
|
||||
would prevent sending WebSocket frames of length 0.
|
||||
|
||||
If the read function calls `curl_ws_start_frame()` however, a return
|
||||
value of 0 is *not* treated as an end of file and libcurl calls
|
||||
the read function again.
|
||||
|
||||
# FLAGS
|
||||
|
||||
Supports all flags documented in curl_ws_meta(3).
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue