diff options
author | Adam <Adam@anope.org> | 2013-08-11 15:46:59 -0400 |
---|---|---|
committer | Adam <Adam@anope.org> | 2013-08-11 15:48:46 -0400 |
commit | 812cb04fde10414ba1b13c88bde78f86e6701a5d (patch) | |
tree | fc96432c599f118f42642126bd88eaabac41e1d0 /modules/commands/os_dns.cpp | |
parent | 1314d5b4f159a5a4964bf192b9e062b823ccdf62 (diff) |
Add DNS Notify support
Diffstat (limited to 'modules/commands/os_dns.cpp')
-rw-r--r-- | modules/commands/os_dns.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
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<Anope::string, ci::less>::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<Anope::string, ci::less>::iterator it = s->zones.begin(), it_end = s->zones.end(); it != it_end; ++it) + dnsmanager->Notify(*it); + } } void DelIP(CommandSource &source, const std::vector<Anope::string> ¶ms) @@ -485,7 +493,11 @@ class CommandOSDNS : public Command } if (s->Active() && dnsmanager) + { dnsmanager->UpdateSerial(); + for (std::set<Anope::string, ci::less>::iterator it = s->zones.begin(), it_end = s->zones.end(); it != it_end; ++it) + dnsmanager->Notify(*it); + } return; } |