Commit 7daf90c7 authored by Chad Austin's avatar Chad Austin Committed by Facebook GitHub Bot

fix link error on gcc 10

Summary:
Building Folly on Fedora 32 fails with a link error, saying
SingletonVault::kDefaultShutdownTimeout_ is undefined. I did not
investigate, but this constant is only used in one place, so inline
it.

Reviewed By: yfeldblum

Differential Revision: D22713828

fbshipit-source-id: 707797eaef4633e642d07b2b02d9f55187afb99f
parent 008f5538
...@@ -40,8 +40,6 @@ ...@@ -40,8 +40,6 @@
namespace folly { namespace folly {
constexpr std::chrono::seconds SingletonVault::kDefaultShutdownTimeout_;
#if FOLLY_SINGLETON_HAVE_DLSYM #if FOLLY_SINGLETON_HAVE_DLSYM
namespace detail { namespace detail {
static void singleton_hs_init_weak(int* argc, char** argv[]) static void singleton_hs_init_weak(int* argc, char** argv[])
......
...@@ -572,9 +572,7 @@ class SingletonVault { ...@@ -572,9 +572,7 @@ class SingletonVault {
Type type_; Type type_;
std::atomic<bool> shutdownTimerStarted_{false}; std::atomic<bool> shutdownTimerStarted_{false};
static constexpr std::chrono::seconds kDefaultShutdownTimeout_{ std::chrono::milliseconds shutdownTimeout_{std::chrono::minutes{5}};
std::chrono::seconds{5 * 60}};
std::chrono::milliseconds shutdownTimeout_{kDefaultShutdownTimeout_};
Synchronized<std::vector<std::string>> shutdownLog_; Synchronized<std::vector<std::string>> shutdownLog_;
}; };
......
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