From d505d77b7e5657c3ef228fbee0d39b0a5dc5b9cd Mon Sep 17 00:00:00 2001 From: Casey Bodley Date: Fri, 20 Apr 2018 11:47:37 -0400 Subject: [PATCH] random: revert change from boost::optional to std::optional somehow this was breaking the seeding of thread-local engines on gcc. we'll have to investigate this further, but for now i'm reverting this piece to get messengers working again Fixes: http://tracker.ceph.com/issues/23778 Signed-off-by: Casey Bodley --- src/include/random.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/include/random.h b/src/include/random.h index 63593e8e601a7..cbfee2d7235b1 100644 --- a/src/include/random.h +++ b/src/include/random.h @@ -17,8 +17,8 @@ #include #include -#include #include +#include // Basic random number facility, adapted from N3551: namespace ceph::util { @@ -114,7 +114,7 @@ void randomize_rng() template EngineT& engine() { - thread_local std::optional rng_engine; + thread_local boost::optional rng_engine; if (!rng_engine) { rng_engine.emplace(EngineT()); -- 2.39.5