[master] 8c77b5d Get the sign right on the overflow test

Poul-Henning Kamp phk at FreeBSD.org
Tue Feb 2 10:14:51 CET 2016


commit 8c77b5df134b32abec2c8c5998b7a112303d1e05
Author: Poul-Henning Kamp <phk at FreeBSD.org>
Date:   Tue Feb 2 09:14:27 2016 +0000

    Get the sign right on the overflow test
    
    Spotted by:	fgs

diff --git a/bin/varnishd/cache/cache_panic.c b/bin/varnishd/cache/cache_panic.c
index 070f00d..d670326 100644
--- a/bin/varnishd/cache/cache_panic.c
+++ b/bin/varnishd/cache/cache_panic.c
@@ -141,8 +141,8 @@ pan_ws(struct vsb *vsb, const struct ws *ws)
 	if (pan_already(vsb, ws))
 		return;
 	VSB_indent(vsb, 2);
-	if (ws->id[0] & 0x20)
-		VSB_printf(vsb, "OVERFLOW ");
+	if (!(ws->id[0] & 0x20))
+		VSB_printf(vsb, "OVERFLOWED ");
 	VSB_printf(vsb, "id = \"%s\",\n",  ws->id);
 	VSB_printf(vsb, "{s,f,r,e} = {%p",  ws->s);
 	if (ws->f > ws->s)



More information about the varnish-commit mailing list