]> granicus.if.org Git - pdns/commitdiff
teach Netmask is can be 'empty', like DNSName.
authorbert hubert <bert.hubert@netherlabs.nl>
Wed, 11 Nov 2015 09:15:55 +0000 (10:15 +0100)
committerbert hubert <bert.hubert@netherlabs.nl>
Wed, 11 Nov 2015 09:15:55 +0000 (10:15 +0100)
pdns/iputils.hh

index b035809ea79e2f6b6fb9d8b074be525305395610..db7670a67b71e48803484bd16949b055a10382f1 100644 (file)
@@ -358,6 +358,11 @@ public:
     return tie(d_network, d_bits) == tie(rhs.d_network, rhs.d_bits);
   }
 
+  bool empty() const 
+  {
+    return d_network.sin4.sin_family==0;
+  }
+
 private:
   ComboAddress d_network;
   uint32_t d_mask;