[master] f87c8e33c Polish

Dridi Boukelmoune dridi.boukelmoune at gmail.com
Wed Apr 3 14:33:08 UTC 2019


commit f87c8e33ceeb35819e89e18dc21520f74db6e6d0
Author: Dridi Boukelmoune <dridi.boukelmoune at gmail.com>
Date:   Wed Apr 3 13:53:28 2019 +0200

    Polish

diff --git a/bin/varnishd/cache/cache_obj.c b/bin/varnishd/cache/cache_obj.c
index d46f4e4da..4c0ec76bb 100644
--- a/bin/varnishd/cache/cache_obj.c
+++ b/bin/varnishd/cache/cache_obj.c
@@ -116,13 +116,10 @@ obj_deleteboc(struct boc **p)
 {
 	struct boc *boc;
 
-	AN(p);
-	boc = *p;
-	*p = NULL;
+	TAKE_OBJ_NOTNULL(boc, p, BOC_MAGIC);
 	Lck_Delete(&boc->mtx);
 	AZ(pthread_cond_destroy(&boc->cond));
-	if (boc->vary != NULL)
-		free(boc->vary);
+	free(boc->vary);
 	FREE_OBJ(boc);
 }
 


More information about the varnish-commit mailing list