Fix a leak reported by coverity when we cycle a backend.
AuthLua4::AuthLua4(const std::string& fname) { }
bool AuthLua4::updatePolicy(const DNSName &qname, QType qtype, const DNSName &zonename, DNSPacket *packet) { return false; }
+AuthLua4::~AuthLua4() { }
#else
return d_update_policy(upq);
}
+AuthLua4::~AuthLua4() { }
+
#endif
}
else
{
- d_pdl = new AuthLua(fname);
+ d_pdl = std::unique_ptr<AuthLua>(new AuthLua(fname));
}
fname = ::arg()["lua-dnsupdate-policy-script"];
if (fname.empty())
}
else
{
- d_update_policy_lua = new AuthLua4(fname);
+ d_update_policy_lua = std::unique_ptr<AuthLua4>(new AuthLua4(fname));
}
}
bool d_logDNSDetails;
bool d_doIPv6AdditionalProcessing;
bool d_doDNAME;
- AuthLua* d_pdl;
- AuthLua4* d_update_policy_lua;
+ std::unique_ptr<AuthLua> d_pdl;
+ std::unique_ptr<AuthLua4> d_update_policy_lua;
UeberBackend B; // every thread an own instance
DNSSECKeeper d_dk; // B is shared with DNSSECKeeper