summaryrefslogtreecommitdiff
path: root/src/or/dns.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/or/dns.c')
-rw-r--r--src/or/dns.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/or/dns.c b/src/or/dns.c
index ffd30c89d8..8951780931 100644
--- a/src/or/dns.c
+++ b/src/or/dns.c
@@ -301,6 +301,8 @@ dns_get_expiry_ttl(uint32_t ttl)
static void
_free_cached_resolve(cached_resolve_t *r)
{
+ if (!r)
+ return;
while (r->pending_connections) {
pending_connection_t *victim = r->pending_connections;
r->pending_connections = victim->next;