From 95ade4c9ccc4e31f5fbe094ac0702207045023a9 Mon Sep 17 00:00:00 2001 From: Andrii Grynenko Date: Fri, 19 Feb 2016 11:19:18 -0800 Subject: [PATCH] Fix EventBaseOnDestructionCallback to loop FiberManager Summary: EventBase loop should do it as well, but it's possible for LoopCallback to be removed before EventBaseOnDestructionCallback. Reviewed By: pavlo-fb Differential Revision: D2951303 fb-gh-sync-id: 43f5a91e7ecffa7ab7feec32fa45e01b28db66a3 shipit-source-id: 43f5a91e7ecffa7ab7feec32fa45e01b28db66a3 --- folly/experimental/fibers/FiberManagerMap.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/folly/experimental/fibers/FiberManagerMap.cpp b/folly/experimental/fibers/FiberManagerMap.cpp index 851a25f4..93eb48ac 100644 --- a/folly/experimental/fibers/FiberManagerMap.cpp +++ b/folly/experimental/fibers/FiberManagerMap.cpp @@ -169,6 +169,7 @@ void EventBaseOnDestructionCallback::runLoopCallback() noexcept { ThreadLocalCache::erase(evb_); while (fm->hasTasks()) { + fm->loopUntilNoReady(); evb_.loopOnce(); } -- 2.34.1