From: Changcheng Liu Date: Thu, 15 Oct 2020 06:53:27 +0000 (+0800) Subject: common/plugin: correct output filename path X-Git-Tag: v16.1.0~824^2~1 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=8863b9db93d5c8367f663b5a54db4c359e9d58f8;p=ceph.git common/plugin: correct output filename path The around code use fname as output in some places. Unify the file name variable to be fname. Signed-off-by: Changcheng Liu --- diff --git a/src/common/PluginRegistry.cc b/src/common/PluginRegistry.cc index 4b8d6156adf..dd85d64fda0 100644 --- a/src/common/PluginRegistry.cc +++ b/src/common/PluginRegistry.cc @@ -144,9 +144,9 @@ int PluginRegistry::load(const std::string &type, if (!library) { string err1(dlerror()); // fall back to plugin_dir - std::string fname2 = cct->_conf.get_val("plugin_dir") + "/" + PLUGIN_PREFIX + + fname = cct->_conf.get_val("plugin_dir") + "/" + PLUGIN_PREFIX + name + PLUGIN_SUFFIX; - library = dlopen(fname2.c_str(), RTLD_NOW); + library = dlopen(fname.c_str(), RTLD_NOW); if (!library) { lderr(cct) << __func__ << " failed dlopen(): \"" << err1.c_str()