[4.1] 9e66583 Remove diagnostic check on active VCL, rather than increase cost by correctly holding the mtx while examining it.

Dridi Boukelmoune dridi.boukelmoune at gmail.com
Mon Sep 12 17:57:14 CEST 2016


commit 9e66583bca900304d91f4eead6e88907edba12db
Author: Poul-Henning Kamp <phk at FreeBSD.org>
Date:   Sat Sep 10 13:14:15 2016 +0000

    Remove diagnostic check on active VCL, rather than increase
    cost by correctly holding the mtx while examining it.

diff --git a/bin/varnishd/cache/cache_vcl.c b/bin/varnishd/cache/cache_vcl.c
index 26e3372..b40e990 100644
--- a/bin/varnishd/cache/cache_vcl.c
+++ b/bin/varnishd/cache/cache_vcl.c
@@ -181,9 +181,6 @@ void
 VCL_Refresh(struct vcl **vcc)
 {
 	CHECK_OBJ_NOTNULL(vcl_active, VCL_MAGIC);
-	AZ(pthread_rwlock_rdlock(&vcl_active->temp_rwl));
-	assert(VCL_WARM(vcl_active));
-	AZ(pthread_rwlock_unlock(&vcl_active->temp_rwl));
 	if (*vcc == vcl_active)
 		return;
 	if (*vcc != NULL)



More information about the varnish-commit mailing list