From 1635bc070c74dd2c1f18be0386e54dec1af1ae2c Mon Sep 17 00:00:00 2001 From: bert hubert Date: Tue, 11 Jun 2013 17:30:22 +0200 Subject: [PATCH] silence a few clang & gcc warnings, partially addressing #856 --- pdns/dynlistener.cc | 1 - pdns/statbag.cc | 2 +- pdns/utility.hh | 5 ----- 3 files changed, 1 insertion(+), 7 deletions(-) diff --git a/pdns/dynlistener.cc b/pdns/dynlistener.cc index a8cb793d4f..32e526da1c 100644 --- a/pdns/dynlistener.cc +++ b/pdns/dynlistener.cc @@ -99,7 +99,6 @@ bool DynListener::testLive(const string& fname) strncpy(addr.sun_path, fname.c_str(), fname.length()); int status = connect(fd, (struct sockaddr*)&addr, sizeof(addr)); - int err=errno; close(fd); return status==0; } diff --git a/pdns/statbag.cc b/pdns/statbag.cc index fbda4291a0..a5e55c73e7 100644 --- a/pdns/statbag.cc +++ b/pdns/statbag.cc @@ -200,7 +200,7 @@ void StatRing::resize(unsigned int newsize) int rpos; vectornewring; for(unsigned int i=startpos;i=0 ? i : i+d_size; + rpos= i; newring.push_back(d_items[rpos%d_size]); } diff --git a/pdns/utility.hh b/pdns/utility.hh index e16de52066..d9463c5bf0 100644 --- a/pdns/utility.hh +++ b/pdns/utility.hh @@ -91,11 +91,6 @@ private: #else typedef int sem_value_t; - uint32_t m_magic; - pthread_mutex_t m_lock; - pthread_cond_t m_gtzero; - sem_value_t m_count; - uint32_t m_nwaiters; #endif protected: -- 2.47.3