[master] 814f2b4 Free some resources on VEV_Destroy
Federico G. Schwindt
fgsch at lodoss.net
Sat Dec 16 20:17:06 UTC 2017
commit 814f2b424ef43283afa77d3a60283d72bcaac737
Author: Federico G. Schwindt <fgsch at lodoss.net>
Date: Sat Dec 16 19:33:28 2017 +0000
Free some resources on VEV_Destroy
diff --git a/lib/libvarnish/vev.c b/lib/libvarnish/vev.c
index ac69754..25494a2 100644
--- a/lib/libvarnish/vev.c
+++ b/lib/libvarnish/vev.c
@@ -219,11 +219,11 @@ VEV_Destroy(struct vev_root **evbp)
{
struct vev_root *evb;
- AN(evbp);
- evb = *evbp;
- *evbp = NULL;
- CHECK_OBJ_NOTNULL(evb, VEV_BASE_MAGIC);
+ TAKE_OBJ_NOTNULL(evb, evbp, VEV_BASE_MAGIC);
assert(evb->thread == pthread_self());
+ free(evb->pfd);
+ free(evb->pev);
+ /* destroy evb->binheap */
evb->magic = 0;
free(evb);
}
More information about the varnish-commit
mailing list