[master] bcdf4f1 Make the reason phrase optional. Basically the backend can drop the reason (OK) when responding to a probe without Varnish declaring the backend sick. Reported by astrosti on https://www.varnish-cache.org/forum/topic/961

Per Buer perbu at varnish-cache.org
Wed May 15 13:18:57 CEST 2013


commit bcdf4f12891eb7ecba395bdf268f8be4c9faa255
Author: Per Buer <perbu at varnish-software.com>
Date:   Wed May 15 13:17:09 2013 +0200

    Make the reason phrase optional.
    Basically the backend can drop the reason (OK) when responding to
    a probe without Varnish declaring the backend sick.
    Reported by astrosti on https://www.varnish-cache.org/forum/topic/961

diff --git a/bin/varnishd/cache/cache_backend_poll.c b/bin/varnishd/cache/cache_backend_poll.c
index 4780165..cd9a215 100644
--- a/bin/varnishd/cache/cache_backend_poll.c
+++ b/bin/varnishd/cache/cache_backend_poll.c
@@ -225,7 +225,7 @@ vbp_poke(struct vbp_target *vt)
 
 	i = sscanf(vt->resp_buf, "HTTP/%*f %u %s", &resp, buf);
 
-	if (i == 2 && resp == vt->probe.exp_status)
+	if ((i == 1 || i == 2) && resp == vt->probe.exp_status)
 		vt->happy |= 1;
 }
 



More information about the varnish-commit mailing list