From 94fcf109f28636f61275ffa87bb1f958db264d1e Mon Sep 17 00:00:00 2001 From: Jason Dillaman Date: Thu, 29 Oct 2020 09:54:42 -0400 Subject: [PATCH] common/config_proxy: expose the 'set_config_values' method This method was previously only available for seastart builds, but librbd will also use it to control the timing of updates to the global config. Signed-off-by: Jason Dillaman --- src/common/config_proxy.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/common/config_proxy.h b/src/common/config_proxy.h index 5632fe4efadc..fd7c2b98063c 100644 --- a/src/common/config_proxy.h +++ b/src/common/config_proxy.h @@ -124,11 +124,12 @@ public: ConfigValues* operator->() noexcept { return &values; } -#ifdef WITH_SEASTAR void set_config_values(const ConfigValues& val) { +#ifndef WITH_SEASTAR + std::lock_guard l{lock}; +#endif values = val; } -#endif int get_val(const std::string_view key, char** buf, int len) const { std::lock_guard l{lock}; return config.get_val(values, key, buf, len); -- 2.47.3