]> git.ipfire.org Git - thirdparty/pdns.git/blobdiff - pdns/dynlistener.cc
auth: switch circleci mssql image
[thirdparty/pdns.git] / pdns / dynlistener.cc
index ceb3dd4119c2e8d70f4c7fa0ccc0fe899fb404c4..c3a1dc7e3e34245c81b98a7a1de4e0d9709b10d9 100644 (file)
@@ -166,19 +166,12 @@ void DynListener::listenOnTCP(const ComboAddress& local)
 
 
 DynListener::DynListener(const ComboAddress& local) :
-  d_tcp(true),
-  d_client(-1),
-  d_tid(0),
-  d_ppid(0)
+  d_tcp(true)
 {
   listenOnTCP(local);
 }
 
-DynListener::DynListener(const string &progname) :
-  d_client(-1),
-  d_tid(0),
-  d_ppid(0),
-  d_s(-1)
+DynListener::DynListener(const string &progname)
 {
 
   if(!progname.empty()) {
@@ -206,7 +199,6 @@ DynListener::DynListener(const string &progname) :
   }
   else
     d_nonlocal=false; // we listen on stdin!
-  d_tcp=false;
 }
 
 void DynListener::go()
@@ -229,7 +221,7 @@ string DynListener::getLine()
   vector<char> mesg;
   mesg.resize(1024000);
 
-  int len;
+  ssize_t len;
 
   ComboAddress remote;
   socklen_t remlen=remote.getSocklen();
@@ -292,12 +284,12 @@ string DynListener::getLine()
     else if(len==0)
       throw PDNSException("Guardian exited - going down as well");
 
-    if(len == (int)mesg.size())
+    if(static_cast<size_t>(len) == mesg.size())
       throw PDNSException("Line on control console was too long");
 
     mesg[len]=0;
   }
-  
+
   return &mesg[0];
 }