mirror of
https://github.com/boostorg/beast.git
synced 2025-07-29 20:37:31 +02:00
@ -4,6 +4,7 @@ Version 212:
|
||||
* flat_stream tests and tidy
|
||||
* stranded_socket tests and tidy
|
||||
* buffers_front tests
|
||||
* Improved websocket stream documentation
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
|
@ -56,17 +56,17 @@ following operations to be active at the same time:
|
||||
* [link beast.ref.boost__beast__websocket__stream.async_ping `async_ping`] or [link beast.ref.boost__beast__websocket__stream.async_pong `async_pong`]
|
||||
* [link beast.ref.boost__beast__websocket__stream.async_close `async_close`]
|
||||
|
||||
For example, the following code is malformed, because the program is
|
||||
attempting to perform two simultaneous reads:
|
||||
For example, the following code is produces undefined behavior, because the
|
||||
program is attempting to perform two simultaneous reads:
|
||||
|
||||
[ws_snippet_24]
|
||||
|
||||
However, this code is well-formed:
|
||||
However, this code is correct:
|
||||
|
||||
[ws_snippet_25]
|
||||
|
||||
The implementation uses composed asynchronous operations; although
|
||||
some individiual operations can perform both reads and writes, this
|
||||
some individual operations can perform both reads and writes, this
|
||||
behavior is coordinated internally to make sure the underlying stream
|
||||
is operated in a safe fashion. This allows an asynchronous read operation
|
||||
to respond to a received ping frame even while a user-initiated call to
|
||||
|
@ -30,7 +30,16 @@ enum class status : unsigned
|
||||
unknown = 0,
|
||||
|
||||
continue_ = 100,
|
||||
|
||||
/** Switching Protocols
|
||||
|
||||
This status indicates that a request to switch to a new
|
||||
protocol was accepted and applied by the server. A successful
|
||||
response to a WebSocket Upgrade HTTP request will have this
|
||||
code.
|
||||
*/
|
||||
switching_protocols = 101,
|
||||
|
||||
processing = 102,
|
||||
|
||||
ok = 200,
|
||||
|
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user