From: Otto Moerbeek Date: Mon, 15 May 2023 10:00:58 +0000 (+0200) Subject: Process review comments X-Git-Tag: rec-4.9.0-beta1~19^2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=refs%2Fpull%2F12790%2Fhead;p=thirdparty%2Fpdns.git Process review comments --- diff --git a/.clang-tidy.full b/.clang-tidy.full index e4a95882a6..43754f5983 100644 --- a/.clang-tidy.full +++ b/.clang-tidy.full @@ -253,7 +253,7 @@ CheckOptions: - key: modernize-pass-by-value.ValuesOnly value: 'false' - key: readability-function-cognitive-complexity.IgnoreMacros - value: 'false' + value: 'true' - key: modernize-loop-convert.IncludeStyle value: llvm - key: cert-str34-c.DiagnoseSignedUnsignedCharComparisons diff --git a/pdns/recursordist/rec-main.cc b/pdns/recursordist/rec-main.cc index cf09ccbb8a..d5f3108113 100644 --- a/pdns/recursordist/rec-main.cc +++ b/pdns/recursordist/rec-main.cc @@ -1254,7 +1254,7 @@ void broadcastFunction(const pipefunc_t& func) continue; } - ThreadMSG* tmsg = new ThreadMSG(); // NOLINT: manual onwership handling + ThreadMSG* tmsg = new ThreadMSG(); // NOLINT: manual ownership handling tmsg->func = func; tmsg->wantAnswer = true; if (write(threadInfo.pipes.writeToThread, &tmsg, sizeof(tmsg)) != sizeof(tmsg)) { // NOLINT: sizeof correct @@ -1348,7 +1348,7 @@ T broadcastAccFunction(const std::function& func) if (resp) { ret += *resp; - delete resp; // NOLINT: manual ownershipm handling + delete resp; // NOLINT: manual ownership handling resp = nullptr; } // coverity[leaked_storage] @@ -1915,7 +1915,6 @@ static int serviceMain(Logr::log_t log) // NOLINT(readability-function-cognitive initDontQuery(log); - /* this needs to be done before parseACLs(), which call broadcastFunction() */ RecThreadInfo::setWeDistributeQueries(::arg().mustDo("pdns-distributes-queries")); if (RecThreadInfo::weDistributeQueries()) { SLOG(g_log << Logger::Warning << "PowerDNS Recursor itself will distribute queries over threads" << endl,