Call read from executor

This commit is contained in:
badaix 2022-09-08 11:39:36 +02:00
parent 051ba91cfc
commit 6b24ec6a3d
2 changed files with 7 additions and 4 deletions

View file

@ -150,7 +150,7 @@ void PosixStream::do_read()
{
LOG(INFO, LOG_TAG) << "next read < 0 (" << getName() << "): " << std::chrono::duration_cast<std::chrono::microseconds>(next_read).count() / 1000.
<< " ms\n";
do_read();
boost::asio::post(strand_, [this] { do_read(); });
}
else
{