From: Klaus Darilion Date: Tue, 24 May 2016 13:23:56 +0000 (+0000) Subject: pdns_control notify: make sure PDNS is either master, or slave with renotify X-Git-Tag: auth-4.1.4^2~4^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e6eb943bcb845007fc3e7b3e097822b9cf1752f5;p=pdns pdns_control notify: make sure PDNS is either master, or slave with renotify (cherry picked from commit e64b1e21a4090316c06ef9b7112092db6bb4feff) (cherry picked from commit 0c54189148e31230768b67f2338991e94927d49d) --- diff --git a/pdns/dynhandler.cc b/pdns/dynhandler.cc index 3d681cd2a..0f476791d 100644 --- a/pdns/dynhandler.cc +++ b/pdns/dynhandler.cc @@ -261,7 +261,7 @@ string DLNotifyHostHandler(const vector&parts, Utility::pid_t ppid) ostringstream os; if(parts.size()!=3) return "syntax: notify-host domain ip"; - if(!::arg().mustDo("master") && !::arg().mustDo("slave-renotify")) + if(!::arg().mustDo("master") && !(::arg().mustDo("slave") && ::arg().mustDo("slave-renotify"))) return "PowerDNS not configured as master or slave with re-notifications"; DNSName domain; @@ -289,7 +289,7 @@ string DLNotifyHandler(const vector&parts, Utility::pid_t ppid) UeberBackend B; if(parts.size()!=2) return "syntax: notify domain"; - if(!::arg().mustDo("master") && !::arg().mustDo("slave-renotify")) + if(!::arg().mustDo("master") && !(::arg().mustDo("slave") && ::arg().mustDo("slave-renotify"))) return "PowerDNS not configured as master or slave with re-notifications"; L<