[master] d06028a Dont leak ->class.

Poul-Henning Kamp phk at FreeBSD.org
Tue Aug 29 12:17:05 CEST 2017


commit d06028a1d89a36c05c76f520f842f3537d4354db
Author: Poul-Henning Kamp <phk at FreeBSD.org>
Date:   Tue Aug 29 10:16:31 2017 +0000

    Dont leak ->class.
    
    Spotted by:	fgs

diff --git a/lib/libvarnish/vsmw.c b/lib/libvarnish/vsmw.c
index 1276b41..41b1fa2 100644
--- a/lib/libvarnish/vsmw.c
+++ b/lib/libvarnish/vsmw.c
@@ -214,6 +214,7 @@ vsmw_delseg(struct vsmw *vsmw, struct vsmwseg *seg, int fixidx)
 	VTAILQ_REMOVE(&vsmw->segs, seg, list);
 	AZ(unlinkat(vsmw->vdirfd, seg->fn, 0));
 	REPLACE(seg->fn, NULL);
+	REPLACE(seg->class, NULL);
 	REPLACE(seg->id, NULL);
 	FREE_OBJ(seg);
 



More information about the varnish-commit mailing list