]> granicus.if.org Git - pdns/commitdiff
fix up pdns_recursor compilation, improve reporting of signing errors in AXFR
authorBert Hubert <bert.hubert@netherlabs.nl>
Tue, 8 Feb 2011 16:28:06 +0000 (16:28 +0000)
committerBert Hubert <bert.hubert@netherlabs.nl>
Tue, 8 Feb 2011 16:28:06 +0000 (16:28 +0000)
git-svn-id: svn://svn.powerdns.com/pdns/trunk/pdns@1997 d19b8d6e-7fed-0310-83ef-9ca221ded41b

pdns/Makefile.am
pdns/pdns_recursor.cc
pdns/rec_channel_rec.cc
pdns/recursor_cache.hh
pdns/signingpipe.cc
pdns/syncres.hh

index 210fe1e805ecbc49bcbb020207b137afa8133014..8d006b2be4efb4ddbbd6a0f546b3c0ef516ce624 100644 (file)
@@ -151,14 +151,14 @@ dnsreplay_LDADD= $(BOOST_PROGRAM_OPTIONS_LIBS)
 
 nproxy_SOURCES=nproxy.cc dnsparser.cc dnsrecords.cc dnsparser.hh  \
        rcpgenerator.cc rcpgenerator.hh base64.cc base64.hh dnswriter.cc dnswriter.hh \
-       sillyrecords.cc selectmplexer.cc pollmplexer.cc  mplexer.hh
+       sillyrecords.cc selectmplexer.cc   mplexer.hh
 
 nproxy_LDFLAGS= @DYNLINKFLAGS@ @THREADFLAGS@ $(BOOST_PROGRAM_OPTIONS_LDFLAGS)
 nproxy_LDADD= $(BOOST_PROGRAM_OPTIONS_LIBS)
 
 notify_SOURCES=notify.cc dnsparser.cc dnsrecords.cc dnsparser.hh  \
        rcpgenerator.cc rcpgenerator.hh base64.cc base64.hh dnswriter.cc dnswriter.hh \
-       sillyrecords.cc selectmplexer.cc pollmplexer.cc nsecrecords.cc base32.cc misc.cc unix_utility.cc \
+       sillyrecords.cc selectmplexer.cc nsecrecords.cc base32.cc misc.cc unix_utility.cc \
        logger.cc qtype.cc statbag.cc
 
 notify_LDFLAGS= @DYNLINKFLAGS@ @THREADFLAGS@ $(BOOST_PROGRAM_OPTIONS_LDFLAGS)
@@ -192,7 +192,7 @@ base64.cc base64.hh zoneparser-tng.cc zoneparser-tng.hh rec_channel.cc rec_chann
 rec_channel_rec.cc selectmplexer.cc epollmplexer.cc sillyrecords.cc htimer.cc htimer.hh \
 aes/dns_random.cc aes/aescrypt.c aes/aeskey.c aes/aestab.c aes/aes_modes.c \
 lua-pdns-recursor.cc lua-pdns-recursor.hh randomhelper.cc  \
-recpacketcache.cc recpacketcache.hh dns.cc nsecrecords.cc base32.cc pollmplexer.cc
+recpacketcache.cc recpacketcache.hh dns.cc nsecrecords.cc base32.cc 
 
 #../modules/gmysqlbackend/smysql.cc 
 
index 5e87f19e9961b851f516654472a5df9b00d0359d..141f48613469e1c6ebfcb6a25e34d6103c94de5d 100644 (file)
@@ -441,7 +441,7 @@ int arecvfrom(char *data, int len, int flags, const ComboAddress& fromaddr, int
 string s_pidfname;
 static void writePid(void)
 {
-  ofstream of(s_pidfname.c_str(), ios_base::app);
+  ofstream of(s_pidfname.c_str(), std::ios_base::app);
   if(of)
     of<< Utility::getpid() <<endl;
   else
@@ -530,7 +530,7 @@ void startDoResolve(void *p)
       }
     }
     
-    uint32_t minTTL=numeric_limits<uint32_t>::max();
+    uint32_t minTTL=std::numeric_limits<uint32_t>::max();
     if(res<0) {
       pw.getHeader()->rcode=RCode::ServFail;
       // no commit here, because no record
index 66fa661fcbdd85485aaa51322ad9a26e8309f5f0..82a330423e657baf5a9e7af12be92a7c81892f5c 100644 (file)
@@ -510,7 +510,7 @@ string doTopRemotes()
       counts[*i]++;
     }
 
-  typedef multimap<int, ComboAddress> rcounts_t;
+  typedef std::multimap<int, ComboAddress> rcounts_t;
   rcounts_t rcounts;
   
   for(counts_t::const_iterator i=counts.begin(); i != counts.end(); ++i)
@@ -587,7 +587,7 @@ string RecursorControlParser::getAnswer(const string& question, RecursorControlP
     try {
       parseACLs();
     } 
-    catch(exception& e) 
+    catch(std::exception& e) 
     {
       return e.what() + string("\n");
     }
index f7c9bbb5edcad1625600c6625bbf396dbf7d36dd..18b9c301b07441d415e4e351c3b1c2bdf66d62e0 100644 (file)
@@ -75,7 +75,7 @@ private:
       if(d_records.size()==1)
         return d_records.begin()->d_ttd;
 
-      uint32_t earliest=numeric_limits<uint32_t>::max();
+      uint32_t earliest=std::numeric_limits<uint32_t>::max();
       for(records_t::const_iterator i=d_records.begin(); i != d_records.end(); ++i)
         earliest=min(earliest, i->d_ttd);
       return earliest;
index 9641dd2d661515a441c1158f3b55ec7344e3e4d2..61ed09c11419bd8d26277819d8f410aaa6854b45 100644 (file)
@@ -267,8 +267,9 @@ try
   }
   close(fd);
 }
-catch(...)
+catch(std::exception& e)
 {
+  cerr<<"Signing thread died because of std::exception: "<<e.what()<<endl;
   close(fd);
 }
 
index d34954061af25f8c52a2f226781224f14e1724ae..7f7fae9cf7f3aa66e8a24228e6728e3f83bde115 100644 (file)
@@ -256,7 +256,7 @@ public:
     {
       if(d_collection.empty())
         return 0;
-      double ret=numeric_limits<double>::max();
+      double ret=std::numeric_limits<double>::max();
       double tmp;
       for(collection_t::iterator pos=d_collection.begin(); pos != d_collection.end(); ++pos) {
         if((tmp=pos->second.get(now)) < ret) {
@@ -430,7 +430,7 @@ struct PacketID
   }
 };
 
-struct PacketIDBirthdayCompare: public binary_function<PacketID, PacketID, bool>  
+struct PacketIDBirthdayCompare: public std::binary_function<PacketID, PacketID, bool>  
 {
   bool operator()(const PacketID& a, const PacketID& b) const
   {