Parcourir la source

[trac534] Fix NS & DNAME in apex

Getting the NS returned delegation, it checked only if the callback is
enabled there and it was enabled because of DNAME.
Michal 'vorner' Vaner il y a 14 ans
Parent
commit
4265faedd3
1 fichiers modifiés avec 2 ajouts et 2 suppressions
  1. 2 2
      src/lib/datasrc/memory_datasrc.cc

+ 2 - 2
src/lib/datasrc/memory_datasrc.cc

@@ -286,8 +286,8 @@ struct MemoryZone::MemoryZoneImpl {
         Domain::const_iterator found;
 
         // If the node callback is enabled, this may be a zone cut.  If it
-        // has a NS RR, we should return a delegation.
-        if (node->isCallbackEnabled()) {
+        // has a NS RR, we should return a delegation, but not in the apex.
+        if (node->isCallbackEnabled() && node->getName() != origin_) {
             found = node->getData()->find(RRType::NS());
             if (found != node->getData()->end()) {
                 return (FindResult(DELEGATION, found->second));