]> granicus.if.org Git - pdns/commitdiff
Christoph Meerwald discovered that our 'SOA freshness checking' actually also looked...
authorBert Hubert <bert.hubert@netherlabs.nl>
Thu, 9 Jun 2011 13:14:28 +0000 (13:14 +0000)
committerBert Hubert <bert.hubert@netherlabs.nl>
Thu, 9 Jun 2011 13:14:28 +0000 (13:14 +0000)
git-svn-id: svn://svn.powerdns.com/pdns/trunk/pdns@2209 d19b8d6e-7fed-0310-83ef-9ca221ded41b

pdns/resolver.cc

index f043baad4e48655c2390d70209879d1ff86e6ef0..3338ace46c0449a5bcde0918f8a95347a7297b0c 100644 (file)
@@ -238,8 +238,10 @@ bool Resolver::tryGetSOASerial(string* domain, uint32_t *theirSerial, uint32_t *
     }
     if(drc.first.d_type == QType::RRSIG) {
       shared_ptr<RRSIGRecordContent> rrc=boost::dynamic_pointer_cast<RRSIGRecordContent>(drc.first.d_content);
-      *theirInception= std::max(*theirInception, rrc->d_siginception);
-      *theirExpire = std::max(*theirExpire, rrc->d_sigexpire);
+      if(rrc->d_type == QType::SOA) {
+       *theirInception= std::max(*theirInception, rrc->d_siginception);
+       *theirExpire = std::max(*theirExpire, rrc->d_sigexpire);
+      }
     }
   }
   if(!gotSOA)