mirror of
https://github.com/boostorg/beast.git
synced 2025-07-29 20:37:31 +02:00
Refactor read_op
This commit is contained in:
@ -10,6 +10,7 @@ WebSocket:
|
||||
* Refactor write_op
|
||||
* Refactor ping_op
|
||||
* Refactor fail_op
|
||||
* Refactor read_op
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
|
@ -976,6 +976,12 @@ read_some(
|
||||
using boost::asio::buffer;
|
||||
using boost::asio::buffer_cast;
|
||||
using boost::asio::buffer_size;
|
||||
// Make sure the stream is open
|
||||
if(failed_)
|
||||
{
|
||||
ec = boost::asio::error::operation_aborted;
|
||||
return 0;
|
||||
}
|
||||
close_code code{};
|
||||
std::size_t bytes_written = 0;
|
||||
loop:
|
||||
|
Reference in New Issue
Block a user