mirror of
https://github.com/boostorg/beast.git
synced 2025-07-30 12:57:31 +02:00
@ -1,3 +1,7 @@
|
|||||||
|
* Workaround TSAN CI bug.
|
||||||
|
|
||||||
|
--------------------------------------------------------------------------------
|
||||||
|
|
||||||
Version 332:
|
Version 332:
|
||||||
|
|
||||||
* Fix beast::zlib warnings
|
* Fix beast::zlib warnings
|
||||||
|
@ -122,15 +122,21 @@ void
|
|||||||
enable_yield_to::
|
enable_yield_to::
|
||||||
spawn(F0&& f, FN&&... fn)
|
spawn(F0&& f, FN&&... fn)
|
||||||
{
|
{
|
||||||
asio::spawn(ioc_,
|
// dispatch of spawn is a workaround for
|
||||||
[&](yield_context yield)
|
// https://github.com/boostorg/beast/issues/2499
|
||||||
|
asio::dispatch(ioc_,
|
||||||
|
[&]
|
||||||
{
|
{
|
||||||
f(yield);
|
asio::spawn(ioc_,
|
||||||
std::lock_guard<std::mutex> lock{m_};
|
[&](yield_context yield)
|
||||||
if(--running_ == 0)
|
{
|
||||||
cv_.notify_all();
|
f(yield);
|
||||||
}
|
std::lock_guard<std::mutex> lock{m_};
|
||||||
, boost::coroutines::attributes(2 * 1024 * 1024));
|
if(--running_ == 0)
|
||||||
|
cv_.notify_all();
|
||||||
|
}
|
||||||
|
, boost::coroutines::attributes(2 * 1024 * 1024));
|
||||||
|
});
|
||||||
spawn(fn...);
|
spawn(fn...);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user