r2203 - in branches/1.2: . bin/varnishd

des at projects.linpro.no des at projects.linpro.no
Tue Oct 30 12:04:40 CET 2007


Author: des
Date: 2007-10-30 12:04:39 +0100 (Tue, 30 Oct 2007)
New Revision: 2203

Modified:
   branches/1.2/
   branches/1.2/bin/varnishd/cache_center.c
Log:
Merged revisions 2190 via svnmerge from 
svn+ssh://projects.linpro.no/svn/varnish/trunk/varnish-cache

........
  r2190 | phk | 2007-10-29 13:22:38 +0100 (Mon, 29 Oct 2007) | 2 lines
  
  Add more paranoia
........



Property changes on: branches/1.2
___________________________________________________________________
Name: svnmerge-integrated
   - /trunk/varnish-cache:1-2101,2104-2107,2115-2120,2122-2130,2133,2151,2153-2154,2157,2161-2162,2166-2168,2175-2176,2180-2184,2186-2189,2191-2192
   + /trunk/varnish-cache:1-2101,2104-2107,2115-2120,2122-2130,2133,2151,2153-2154,2157,2161-2162,2166-2168,2175-2176,2180-2184,2186-2192

Modified: branches/1.2/bin/varnishd/cache_center.c
===================================================================
--- branches/1.2/bin/varnishd/cache_center.c	2007-10-30 11:04:31 UTC (rev 2202)
+++ branches/1.2/bin/varnishd/cache_center.c	2007-10-30 11:04:39 UTC (rev 2203)
@@ -87,6 +87,9 @@
 {
 	int i;
 
+	CHECK_OBJ_NOTNULL(sp, SESS_MAGIC);
+	CHECK_OBJ_NOTNULL(sp->vcl, VCL_CONF_MAGIC);
+	AZ(sp->obj);
 	assert(sp->xid == 0);
 
 	i = HTC_Complete(sp->htc);
@@ -142,6 +145,10 @@
 cnt_deliver(struct sess *sp)
 {
 
+	CHECK_OBJ_NOTNULL(sp, SESS_MAGIC);
+	CHECK_OBJ_NOTNULL(sp->obj, OBJECT_MAGIC);
+	CHECK_OBJ_NOTNULL(sp->vcl, VCL_CONF_MAGIC);
+
 	sp->t_resp = TIM_real();
 	if (sp->obj->objhead != NULL)
 		EXP_Touch(sp->obj, sp->t_resp);
@@ -183,6 +190,9 @@
 	double dh, dp, da;
 	int i;
 
+	CHECK_OBJ_NOTNULL(sp, SESS_MAGIC);
+	CHECK_OBJ_NOTNULL(sp->vcl, VCL_CONF_MAGIC);
+
 	AZ(sp->obj);
 	AZ(sp->bereq);
 	sp->backend = NULL;
@@ -300,6 +310,9 @@
 {
 	int i;
 
+	CHECK_OBJ_NOTNULL(sp, SESS_MAGIC);
+	CHECK_OBJ_NOTNULL(sp->vcl, VCL_CONF_MAGIC);
+
 	AN(sp->bereq);
 	CHECK_OBJ_NOTNULL(sp->backend, BACKEND_MAGIC);
 	i = Fetch(sp);
@@ -423,6 +436,10 @@
 cnt_hit(struct sess *sp)
 {
 
+	CHECK_OBJ_NOTNULL(sp, SESS_MAGIC);
+	CHECK_OBJ_NOTNULL(sp->obj, OBJECT_MAGIC);
+	CHECK_OBJ_NOTNULL(sp->vcl, VCL_CONF_MAGIC);
+
 	assert(!sp->obj->pass);
 
 	VCL_hit_method(sp);
@@ -487,6 +504,7 @@
 	uintptr_t u;
 
 	CHECK_OBJ_NOTNULL(sp, SESS_MAGIC);
+	CHECK_OBJ_NOTNULL(sp->vcl, VCL_CONF_MAGIC);
 
 	if (sp->obj == NULL) {
 
@@ -580,6 +598,10 @@
 cnt_miss(struct sess *sp)
 {
 
+	CHECK_OBJ_NOTNULL(sp, SESS_MAGIC);
+	CHECK_OBJ_NOTNULL(sp->obj, OBJECT_MAGIC);
+	CHECK_OBJ_NOTNULL(sp->vcl, VCL_CONF_MAGIC);
+
 	http_FilterHeader(sp, HTTPH_R_FETCH);
 	VCL_miss_method(sp);
 	if (sp->handling == VCL_RET_ERROR) {
@@ -639,6 +661,8 @@
 cnt_pass(struct sess *sp)
 {
 
+	CHECK_OBJ_NOTNULL(sp, SESS_MAGIC);
+	CHECK_OBJ_NOTNULL(sp->vcl, VCL_CONF_MAGIC);
 	AZ(sp->obj);
 
 	http_FilterHeader(sp, HTTPH_R_PASS);
@@ -685,6 +709,9 @@
 cnt_pipe(struct sess *sp)
 {
 
+	CHECK_OBJ_NOTNULL(sp, SESS_MAGIC);
+	CHECK_OBJ_NOTNULL(sp->vcl, VCL_CONF_MAGIC);
+
 	sp->wrk->acct.pipe++;
 	http_FilterHeader(sp, HTTPH_R_PIPE);
 
@@ -720,8 +747,9 @@
 cnt_recv(struct sess *sp)
 {
 
+	CHECK_OBJ_NOTNULL(sp, SESS_MAGIC);
+	CHECK_OBJ_NOTNULL(sp->vcl, VCL_CONF_MAGIC);
 	AZ(sp->obj);
-	AN(sp->vcl);
 
 	VCL_recv_method(sp);
 
@@ -759,6 +787,7 @@
 {
 	int done;
 
+	CHECK_OBJ_NOTNULL(sp, SESS_MAGIC);
 	AZ(sp->restarts);
 	AZ(sp->obj);
 	AZ(sp->vcl);




More information about the varnish-commit mailing list