]> granicus.if.org Git - libevent/commitdiff
evdns_shutdown fix from Adam Langley
authorNiels Provos <provos@gmail.com>
Sun, 27 May 2007 06:27:11 +0000 (06:27 +0000)
committerNiels Provos <provos@gmail.com>
Sun, 27 May 2007 06:27:11 +0000 (06:27 +0000)
svn:r357

evdns.c

diff --git a/evdns.c b/evdns.c
index b1e0644eac815ae45085629165510e2e32e981e5..d76be3354ba4dcb4da6fc629d4245d1f6583a7ac 100644 (file)
--- a/evdns.c
+++ b/evdns.c
@@ -2954,6 +2954,8 @@ evdns_shutdown(int fail_requests)
                if (server->socket >= 0)
                        CLOSE_SOCKET(server->socket);
                (void) event_del(&server->event);
+               if (server->state == 0)
+                        (void) event_del(&server->timeout_event);
                free(server);
                if (server_next == server_head)
                        break;