]> git.ipfire.org Git - thirdparty/pdns.git/blobdiff - pdns/saxfr.cc
Merge pull request #8223 from PowerDNS/omoerbeek-patch-1
[thirdparty/pdns.git] / pdns / saxfr.cc
index 9b18d422e7fffb8e50092d8c179776a08fae8106..641008582ef363bfb33d43daba9d06ca79e52592 100644 (file)
@@ -83,7 +83,6 @@ try
   }
 
   reportAllTypes();
-  dns_random_init("0123456789abcdef");
 
   vector<uint8_t> packet;
   uint16_t len;
@@ -124,7 +123,7 @@ try
       len = htons(packet.size());
       if(sock.write((char *) &len, 2) != 2)
         throw PDNSException("tcp write failed");
-      sock.writen(string((char*)&*packet.begin(), (char*)&*packet.end()));
+      sock.writen(string((char*)&packet[0], packet.size()));
       if(sock.read((char *) &len, 2) != 2)
         throw PDNSException("tcp read failed");
 
@@ -178,7 +177,7 @@ try
   if(sock.write((char *) &len, 2) != 2)
     throw PDNSException("tcp write failed");
 
-  sock.writen(string((char*)&*packet.begin(), (char*)&*packet.end()));
+  sock.writen(string(packet.begin(), packet.end()));
 
   bool isNSEC3 = false;
   int soacount=0;