mirror of
https://github.com/libevent/libevent.git
synced 2025-01-31 09:12:55 +08:00
Free evdns_base->req_heads on evdns_base_free
It looks like when we moved from one big inflight-requests list to an n-heads structure, we didn't make evdns_base_free() free the array of heads. This patch should fix that. Found with valgrind
This commit is contained in:
parent
68dc742bf1
commit
859af6772c
2
evdns.c
2
evdns.c
@ -3775,6 +3775,8 @@ evdns_base_free_and_unlock(struct evdns_base *base, int fail_requests)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
mm_free(base->req_heads);
|
||||||
|
|
||||||
EVDNS_UNLOCK(base);
|
EVDNS_UNLOCK(base);
|
||||||
EVTHREAD_FREE_LOCK(base->lock, EVTHREAD_LOCKTYPE_RECURSIVE);
|
EVTHREAD_FREE_LOCK(base->lock, EVTHREAD_LOCKTYPE_RECURSIVE);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user