]> granicus.if.org Git - pdns/commitdiff
Read nameserver parameter from reply in superMasterBackend
authorAki Tuomi <cmouse@desteem.org>
Mon, 15 Jun 2015 11:27:00 +0000 (14:27 +0300)
committerAki Tuomi <cmouse@desteem.org>
Mon, 15 Jun 2015 11:27:00 +0000 (14:27 +0300)
modules/remotebackend/remotebackend.cc

index fe86a0895898dc087fd7472a949b315ccf10991d..60c882bbd0d691e224e88fa182c58ff4649ebc11 100644 (file)
@@ -716,9 +716,12 @@ bool RemoteBackend::superMasterBackend(const string &ip, const string &domain, c
    *ddb = this;
    
    // we allow simple true as well...
-   if (answer["result"].IsObject() && answer["result"].HasMember("account")) 
-     *account = getString(answer["result"]["account"]);
-
+   if (answer["result"].IsObject()) {
+     if (answer["result"].HasMember("account")) 
+       *account = getString(answer["result"]["account"]);
+     if (answer["result"].HasMember("nameserver"))
+       *nameserver = getString(answer["result"]["nameserver"]);
+   }
    return true;
 }