From: Christian Hofstaedtler Date: Fri, 2 Sep 2016 19:52:36 +0000 (+0200) Subject: Fix warning: types may not be defined in a for-range-declaration X-Git-Tag: dnsdist-1.1.0-beta2~142^2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=refs%2Fpull%2F4407%2Fhead;p=thirdparty%2Fpdns.git Fix warning: types may not be defined in a for-range-declaration As emitted by gcc 6.2.0 20160830 (Debian 6.2.0-2) --- diff --git a/pdns/pdnsutil.cc b/pdns/pdnsutil.cc index ac8555081d..f26891570b 100644 --- a/pdns/pdnsutil.cc +++ b/pdns/pdnsutil.cc @@ -2789,7 +2789,7 @@ loadMainConfig(g_vm["config-dir"].as()); std::vector keys; UeberBackend B("default"); if (B.getTSIGKeys(keys)) { - for(const struct TSIGKey &key : keys) { + for(const TSIGKey &key : keys) { cout << key.name.toString() << " " << key.algorithm.toString() << " " << key.key << endl; } } diff --git a/pdns/tcpreceiver.cc b/pdns/tcpreceiver.cc index c18c1f75a9..5ae781db17 100644 --- a/pdns/tcpreceiver.cc +++ b/pdns/tcpreceiver.cc @@ -1280,7 +1280,7 @@ void TCPNameserver::thread() continue; int sock=-1; - for(const struct pollfd& pfd : d_prfds) { + for(const pollfd& pfd : d_prfds) { if(pfd.revents == POLLIN) { sock = pfd.fd; addrlen=sizeof(remote);