From: Bert Hubert Date: Sun, 5 Apr 2009 19:12:48 +0000 (+0000) Subject: make sure we notice filename changes in the bind backend, closing ticket 228, reporte... X-Git-Tag: rec-3.2~175 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=5552a8e7639e109ed62b8d4471ee34d9289fba68;p=pdns make sure we notice filename changes in the bind backend, closing ticket 228, reported by an anonymous big user. git-svn-id: svn://svn.powerdns.com/pdns/trunk/pdns@1347 d19b8d6e-7fed-0310-83ef-9ca221ded41b --- diff --git a/pdns/backends/bind/bindbackend2.cc b/pdns/backends/bind/bindbackend2.cc index 8e52b783c..03b74a336 100644 --- a/pdns/backends/bind/bindbackend2.cc +++ b/pdns/backends/bind/bindbackend2.cc @@ -565,11 +565,13 @@ void Bind2Backend::loadConfig(string* status) // overwrite what we knew about the domain bbd->d_name=i->name; + + bool filenameChanged = (bbd->d_filename!=i->filename); bbd->d_filename=i->filename; bbd->d_masters=i->masters; - if(!bbd->d_loaded || !bbd->current()) { - // L<name<<"' from file '"<filename<<"'"<d_loaded || !bbd->current()) { + L<name<<"' from file '"<filename<<"'"<id_zone_map[bbd->d_id].setCtime(); staging->id_zone_map[bbd->d_id].d_loaded=true; staging->id_zone_map[bbd->d_id].d_status="parsed into memory at "+nowTime(); - + contents.clear(); // s_stage->id_zone_map[bbd->d_id].d_records->swap(*s_staging_zone_map[bbd->d_id].d_records); }