WebSocket close will automatically drain (API Change):

fix #642

* Calls to stream::close and stream::async_close will
  automatically perform the required read operations

Actions Required:

* Remove calling code which drains the connection after
  calling stream::close or stream::async_close
This commit is contained in:
Vinnie Falco
2017-08-01 20:15:07 -07:00
parent dc6a08d10a
commit 64327739f0
14 changed files with 1233 additions and 898 deletions

View File

@@ -64,8 +64,7 @@ class server
boost::asio::basic_waitable_timer<
clock_type> timer_; // Needed for timeouts
boost::asio::io_service::strand strand_;// Needed when threads > 1
boost::beast::multi_buffer buffer_; // Stores the current message
boost::beast::drain_buffer drain_; // Helps discard data on close
boost::beast::multi_buffer buffer_; // Stores the current message
std::size_t id_; // A small unique id
public: