From 8200ccc2c9062f3f7b339081e36febea9f1720c7 Mon Sep 17 00:00:00 2001 From: Remi Gacogne Date: Mon, 13 Nov 2023 14:23:55 +0100 Subject: [PATCH] dnsdist: Hopefully make clang-tidy happy --- pdns/dnsdist-lua.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pdns/dnsdist-lua.cc b/pdns/dnsdist-lua.cc index 2f2dce8451..2b47f26007 100644 --- a/pdns/dnsdist-lua.cc +++ b/pdns/dnsdist-lua.cc @@ -1880,9 +1880,10 @@ static void setupLuaConfig(LuaContext& luaCtx, bool client, bool configCheck) if (boost::ends_with(ent->d_name, ".conf")) { std::ostringstream namebuf; + // NOLINTNEXTLINE(cppcoreguidelines-pro-bounds-array-to-pointer-decay): this is what dirent is namebuf << dirname << "/" << ent->d_name; - if (stat(namebuf.str().c_str(), &st) || !S_ISREG(st.st_mode)) { + if (stat(namebuf.str().c_str(), &st) != 0 || !S_ISREG(st.st_mode)) { continue; } -- 2.47.2