]> granicus.if.org Git - pdns/commitdiff
silence an error message on very small packets - discovered by John J and Winfried A.
authorBert Hubert <bert.hubert@netherlabs.nl>
Sun, 24 Oct 2010 19:34:23 +0000 (19:34 +0000)
committerBert Hubert <bert.hubert@netherlabs.nl>
Sun, 24 Oct 2010 19:34:23 +0000 (19:34 +0000)
git-svn-id: svn://svn.powerdns.com/pdns/trunk/pdns@1729 d19b8d6e-7fed-0310-83ef-9ca221ded41b

pdns/dns.cc

index 98d52baa772d704940857d246cb7ceca8c58a62a..f930fac6132962dfd9be2595b897302cfcef6f5d 100644 (file)
@@ -48,7 +48,7 @@ private:
 //! compares two dns packets, skipping the header, but including the question and the qtype
 bool dnspacketLessThan(const std::string& a, const std::string& b)
 {
-  if(a.length() < 12 || b.length() < 12) 
+  if(a.length() <= 12 || b.length() <= 12) 
     return a.length() < b.length();
 //    throw runtime_error("Error parsing question in dnspacket comparison: packet too short");