forked from boostorg/beast
Add teardown_role for correct TIME_WAIT behavior (API Change):
* teardown_tag is replaced with teardown_role, a client/server flag used to determine whether the shutdown is performed before or after reading the EOF. This is in accordance with RFC6455 7.1.1: https://tools.ietf.org/html/rfc6455#section-7.1.1 Actions Required: * Modify signatures of teardown and async_teardown to use teardown_role instead of teardown_tag * Change calls to teardown and async_teardown to pass the correct role: client or server depending on context.
This commit is contained in:
@@ -13,6 +13,7 @@
|
||||
#include <boost/beast/config.hpp>
|
||||
#include <boost/beast/websocket/error.hpp>
|
||||
#include <boost/beast/websocket/option.hpp>
|
||||
#include <boost/beast/websocket/role.hpp>
|
||||
#include <boost/beast/websocket/rfc6455.hpp>
|
||||
#include <boost/beast/websocket/detail/frame.hpp>
|
||||
#include <boost/beast/websocket/detail/hybi13.hpp>
|
||||
@@ -145,16 +146,6 @@ class stream
|
||||
using control_cb_type =
|
||||
std::function<void(frame_type, string_view)>;
|
||||
|
||||
/// Identifies the role of a WebSockets stream.
|
||||
enum class role_type
|
||||
{
|
||||
/// Stream is operating as a client.
|
||||
client,
|
||||
|
||||
/// Stream is operating as a server.
|
||||
server
|
||||
};
|
||||
|
||||
// State information for the message being received
|
||||
//
|
||||
struct rd_t
|
||||
|
Reference in New Issue
Block a user