basic_stream: Fix call to net::dispatch

Fixes #2925
This commit is contained in:
Mohammad Nejati
2024-09-04 14:06:42 +00:00
committed by Mohammad Nejati
parent 21545dbcaf
commit cbcf6cb262

View File

@ -325,8 +325,8 @@ public:
(isRead ? "basic_stream::async_read_some"
: "basic_stream::async_write_some")));
net::dispatch(this->get_immediate_executor(),
net::append(std::move(*this), ec, 0));
const auto ex = this->get_immediate_executor();
net::dispatch(ex, net::append(std::move(*this), ec, 0));
}
impl_->close();