websocket: fix curl_ws_recv()

- when data arrived in several chunks, the collection into
  the passed buffer always started at offset 0, overwriting
  the data already there.

adding test_20_07 to verify fix

- debug environment var CURL_WS_CHUNK_SIZE can be used to
  influence the buffer chunk size used for en-/decoding.

Closes #12945
This commit is contained in:
Stefan Eissing 2024-02-15 16:39:40 +01:00 committed by Daniel Stenberg
parent e3461bbd05
commit f0c446ab57
No known key found for this signature in database
GPG key ID: 5CC908FDB71E12C2
4 changed files with 37 additions and 6 deletions

View file

@ -116,3 +116,8 @@ Debug-version of the *ntlm-wb* executable.
OpenLDAP tracing is enabled if this variable exists and its value is 1 or
greater. There is a number of debug levels, refer to *openldap.c* comments.
## CURL_WS_CHUNK_SIZE
Used to influence the buffer chunk size used for WebSocket encoding and
decoding.