From 812cb04fde10414ba1b13c88bde78f86e6701a5d Mon Sep 17 00:00:00 2001 From: Adam Date: Sun, 11 Aug 2013 15:46:59 -0400 Subject: Add DNS Notify support --- modules/commands/os_dns.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'modules/commands') diff --git a/modules/commands/os_dns.cpp b/modules/commands/os_dns.cpp index 1df401112..717cbf29b 100644 --- a/modules/commands/os_dns.cpp +++ b/modules/commands/os_dns.cpp @@ -131,7 +131,11 @@ class DNSServer : public Serializable active = p; if (dnsmanager) + { dnsmanager->UpdateSerial(); + for (std::set::iterator it = zones.begin(), it_end = zones.end(); it != it_end; ++it) + dnsmanager->Notify(*it); + } } void Serialize(Serialize::Data &data) const anope_override @@ -458,7 +462,11 @@ class CommandOSDNS : public Command Log(LOG_ADMIN, source, this) << "to add IP " << params[2] << " to " << s->GetName(); if (s->Active() && dnsmanager) + { dnsmanager->UpdateSerial(); + for (std::set::iterator it = s->zones.begin(), it_end = s->zones.end(); it != it_end; ++it) + dnsmanager->Notify(*it); + } } void DelIP(CommandSource &source, const std::vector ¶ms) @@ -485,7 +493,11 @@ class CommandOSDNS : public Command } if (s->Active() && dnsmanager) + { dnsmanager->UpdateSerial(); + for (std::set::iterator it = s->zones.begin(), it_end = s->zones.end(); it != it_end; ++it) + dnsmanager->Notify(*it); + } return; } -- cgit