From 0c891f1d00d1e1c29ba6ca1c3c355ea6428e7328 Mon Sep 17 00:00:00 2001 From: Nathan Hoad Date: Thu, 30 Apr 2026 14:29:24 -0400 Subject: [PATCH] rgw: Move declaration inline to solve compiler warning about an unused variable. Signed-off-by: Nathan Hoad --- src/rgw/rgw_appmain.cc | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/rgw/rgw_appmain.cc b/src/rgw/rgw_appmain.cc index f1eb20d46657..08ba5dca5470 100644 --- a/src/rgw/rgw_appmain.cc +++ b/src/rgw/rgw_appmain.cc @@ -553,12 +553,11 @@ void rgw::AppMain::init_lua() if (!g_conf().get_val("rgw_lua_enable")) return; rgw::sal::Driver* driver = env.driver; - int r{0}; std::string install_dir; #ifdef WITH_RADOSGW_LUA_PACKAGES rgw::lua::packages_t failed_packages; - r = rgw::lua::install_packages(dpp, driver, null_yield, g_conf().get_val("rgw_luarocks_location"), - failed_packages, install_dir); + int r = rgw::lua::install_packages(dpp, driver, null_yield, g_conf().get_val("rgw_luarocks_location"), + failed_packages, install_dir); if (r < 0) { ldpp_dout(dpp, 5) << "WARNING: failed to install Lua packages from allowlist. error: " << r << dendl; -- 2.47.3