From d599dd4f3bdf957d4099f0ef0913401a910ac97d Mon Sep 17 00:00:00 2001 From: Axel Viala Date: Sat, 17 Sep 2022 13:01:51 +0200 Subject: [PATCH] [clang-tidy] non-init k_size and z_size in secureZone. --- pdns/pdnsutil.cc | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/pdns/pdnsutil.cc b/pdns/pdnsutil.cc index de96f6101f..618b45c83b 100644 --- a/pdns/pdnsutil.cc +++ b/pdns/pdnsutil.cc @@ -2188,16 +2188,14 @@ static bool showZone(DNSSECKeeper& dk, const DNSName& zone, bool exportDS = fals static bool secureZone(DNSSECKeeper& dk, const DNSName& zone) { - // parse attribute - int k_size; - int z_size; // temp var for addKey int64_t id; + // parse attribute string k_algo = ::arg()["default-ksk-algorithm"]; - k_size = ::arg().asNum("default-ksk-size"); + int k_size = ::arg().asNum("default-ksk-size"); string z_algo = ::arg()["default-zsk-algorithm"]; - z_size = ::arg().asNum("default-zsk-size"); + int z_size = ::arg().asNum("default-zsk-size"); if (k_size < 0) { throw runtime_error("KSK key size must be equal to or greater than 0"); -- 2.47.2