Commit 93a1c2fc authored by octal's avatar octal

async: now avoiding to double-reject a whenAll Promise

parent a1b10622
......@@ -1199,6 +1199,8 @@ namespace Async {
WhenContinuation<T> cont(data, index);
it->then(std::move(cont), [=](std::exception_ptr ptr) {
if (data->rejected) return;
data->rejected.store(true);
data->reject(std::move(ptr));
});
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment