r5210 - trunk/varnish-cache/bin/varnishd
phk at varnish-cache.org
phk at varnish-cache.org
Wed Sep 15 09:22:14 CEST 2010
Author: phk
Date: 2010-09-15 09:22:14 +0200 (Wed, 15 Sep 2010)
New Revision: 5210
Modified:
trunk/varnish-cache/bin/varnishd/storage_synth.c
Log:
Lock the sms counters properly
Fixes: #768
Modified: trunk/varnish-cache/bin/varnishd/storage_synth.c
===================================================================
--- trunk/varnish-cache/bin/varnishd/storage_synth.c 2010-09-14 16:57:58 UTC (rev 5209)
+++ trunk/varnish-cache/bin/varnishd/storage_synth.c 2010-09-15 07:22:14 UTC (rev 5210)
@@ -120,6 +120,8 @@
sto->len = vsb_len(vsb);
sto->space = vsb_len(vsb);
obj->len = sto->len;
+ Lck_Lock(&sms_mtx);
VSC_main->sms_nbytes += sto->len;
VSC_main->sms_balloc += sto->len;
+ Lck_Unlock(&sms_mtx);
}
More information about the varnish-commit
mailing list