]> granicus.if.org Git - pdns/commitdiff
SuffixMatchTree: Remove useless code duplication
authorRemi Gacogne <remi.gacogne@powerdns.com>
Fri, 14 Jun 2019 12:02:27 +0000 (14:02 +0200)
committerOtto Moerbeek <otto.moerbeek@open-xchange.com>
Wed, 19 Jun 2019 12:21:31 +0000 (14:21 +0200)
(cherry picked from commit 28ed71086538310bf000071b2d86a1a0fddc35fe)

pdns/dnsname.hh

index f9e1d0ba30b1c7ea4773014dbbc1284aa77c2654..581c0d49268fade7583ffb395f698e8c29ceebfc 100644 (file)
@@ -336,11 +336,7 @@ struct SuffixMatchTree
       return nullptr;
     }
 
-    auto result = lookup(name.getRawLabels());
-    if (result) {
-      return result;
-    }
-    return endNode ? &d_value : nullptr;
+    return lookup(name.getRawLabels());
   }
 
   T* lookup(std::vector<std::string> labels) const