r612 - trunk/varnish-cache/bin/varnishd

phk at projects.linpro.no phk at projects.linpro.no
Wed Aug 2 22:59:46 CEST 2006


Author: phk
Date: 2006-08-02 22:59:46 +0200 (Wed, 02 Aug 2006)
New Revision: 612

Modified:
   trunk/varnish-cache/bin/varnishd/cache_expire.c
Log:
Add an assert, just in case.


Modified: trunk/varnish-cache/bin/varnishd/cache_expire.c
===================================================================
--- trunk/varnish-cache/bin/varnishd/cache_expire.c	2006-08-02 20:54:40 UTC (rev 611)
+++ trunk/varnish-cache/bin/varnishd/cache_expire.c	2006-08-02 20:59:46 UTC (rev 612)
@@ -123,6 +123,12 @@
 			continue;
 		}
 		binheap_delete(exp_heap, o->heap_idx);
+{
+	struct object *o2;
+	o2 = binheap_root(exp_heap);
+	if (o2 != NULL)
+		assert(o2->ttl >= o->ttl);
+}
 		AZ(pthread_mutex_unlock(&exp_mtx));
 		VSL(SLT_ExpPick, 0, "%u", o->xid);
 




More information about the varnish-commit mailing list