mirror of
https://github.com/boostorg/beast.git
synced 2025-07-29 20:37:31 +02:00
@ -4,6 +4,7 @@ Version XXX:
|
||||
* Refactor websocket read
|
||||
* Correct buffer_bytes documentation
|
||||
* Fix examples to dispatch to strand
|
||||
* Ensure basic_stream::close will not throw
|
||||
|
||||
--------------------------------------------------------------------------------
|
||||
|
||||
|
@ -291,8 +291,8 @@ private:
|
||||
template<class Executor2>
|
||||
void on_timer(Executor2 const& ex2);
|
||||
|
||||
void reset(); // set timeouts to never
|
||||
void close(); // cancel everything
|
||||
void reset(); // set timeouts to never
|
||||
void close() noexcept; // cancel everything
|
||||
};
|
||||
|
||||
// We use shared ownership for the state so it can
|
||||
|
@ -143,21 +143,19 @@ template<class Protocol, class Executor, class RatePolicy>
|
||||
void
|
||||
basic_stream<Protocol, Executor, RatePolicy>::
|
||||
impl_type::
|
||||
close()
|
||||
close() noexcept
|
||||
{
|
||||
{
|
||||
error_code ec;
|
||||
socket.close(ec);
|
||||
}
|
||||
timer.cancel();
|
||||
|
||||
|
||||
// have to let the read/write ops cancel the timer,
|
||||
// otherwise we will get error::timeout on close when
|
||||
// we actually want net::error::operation_aborted.
|
||||
//
|
||||
//read.timer.cancel();
|
||||
//write.timer.cancel();
|
||||
try
|
||||
{
|
||||
timer.cancel();
|
||||
}
|
||||
catch(...)
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
|
Reference in New Issue
Block a user