]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
Merge pull request #5313 from ahupowerdns/no-root-age
authorbert hubert <bert.hubert@netherlabs.nl>
Thu, 11 May 2017 16:35:23 +0000 (18:35 +0200)
committerGitHub <noreply@github.com>
Thu, 11 May 2017 16:35:23 +0000 (18:35 +0200)
don't age the root - this was a mistranslation from 3.x to 4.x

pdns/protobuf.cc

index c881e0084b1e2edbe20e9dd8e08c22be53de465c..c7241ad0f20c1edf47fd3b8d24e8148fdc48942f 100644 (file)
@@ -37,7 +37,8 @@ void DNSProtoBufMessage::setQuestion(const DNSName& qname, uint16_t qtype, uint1
 #ifdef HAVE_PROTOBUF
   PBDNSMessage_DNSQuestion* question = d_message.mutable_question();
   if (question) {
-    question->set_qname(qname.toString());
+    if(!qname.empty())
+      question->set_qname(qname.toString());
     question->set_qtype(qtype);
     question->set_qclass(qclass);
   }