summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Bernard <miniupnp@free.fr>2014-12-08 10:21:00 +0100
committerThomas Bernard <miniupnp@free.fr>2014-12-08 10:21:00 +0100
commit8afbdbc470a16d72305cb58cc62e4ff19d191b10 (patch)
treefb070b195b95f70bc844a6f73a2823eb0b525f76
parentf2645f80c135b44a9e82f809662da4bef93e8726 (diff)
downloadlibevent-8afbdbc470a16d72305cb58cc62e4ff19d191b10.tar.gz
Fix mixed declarations and code (forbidden by ISO C90)
-rw-r--r--evdns.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/evdns.c b/evdns.c
index 177d56c1..615cd880 100644
--- a/evdns.c
+++ b/evdns.c
@@ -2171,12 +2171,12 @@ evdns_request_timeout_callback(evutil_socket_t fd, short events, void *arg) {
EVDNS_LOCK(base);
if (req->tx_count >= req->base->global_max_retransmits) {
+ struct nameserver *ns = req->ns;
/* this request has failed */
log(EVDNS_LOG_DEBUG, "Giving up on request %p; tx_count==%d",
arg, req->tx_count);
reply_schedule_callback(req, 0, DNS_ERR_TIMEOUT, NULL);
- struct nameserver *ns = req->ns;
request_finished(req, &REQ_HEAD(req->base, req->trans_id), 1);
nameserver_failed(ns, "request timed out.");
} else {