Handle timekeeperSingleton being nullptr in within()
authorAlex Yarmula <ayarmula@fb.com>
Thu, 19 Oct 2017 20:35:27 +0000 (13:35 -0700)
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>
Thu, 19 Oct 2017 20:47:10 +0000 (13:47 -0700)
commit084ff8d9934675912ee1af8687611eb34a630579
treece2aeb02ea00941c552208c1059c4dabc8593cd9
parentc78133696b5e489fbe20d3ebea51e9c1bf08e2f0
Handle timekeeperSingleton being nullptr in within()

Summary: When timekeeper singleton no longer exists during shutdown and folly::Singleton::try_get() can return nullptr, make sure nullptr is handled gracefully.

Reviewed By: yfeldblum

Differential Revision: D6101311

fbshipit-source-id: fefeddfbd048d1a7632688bb3526db15b685dd72
folly/futures/Future-inl.h
folly/futures/test/TimekeeperTest.cpp