Browse 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 14 years ago
parent
commit
4265faedd3
1 changed files with 2 additions and 2 deletions
  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));