From: Jason Dillaman Date: Thu, 29 Oct 2020 13:54:42 +0000 (-0400) Subject: common/config_proxy: expose the 'set_config_values' method X-Git-Tag: v16.1.0~711^2~2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=94fcf109f28636f61275ffa87bb1f958db264d1e;p=ceph.git 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 --- 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);