<div dir="ltr"><div>ctx->method is not a bit mask. This change makes it look like it is.</div><div>Why are we changing this?</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Nov 2, 2017 at 10:12 PM, Nils Goroll <span dir="ltr"><<a href="mailto:nils.goroll@uplex.de" target="_blank">nils.goroll@uplex.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
commit 6155df1eee573bd7325d9155084d40<wbr>e858530021<br>
Author: Nils Goroll <<a href="mailto:nils.goroll@uplex.de">nils.goroll@uplex.de</a>><br>
Date:   Thu Nov 2 14:10:26 2017 +0100<br>
<br>
    cleanup<br>
<br>
diff --git a/bin/varnishd/cache/cache_<wbr>vrt.c b/bin/varnishd/cache/cache_<wbr>vrt.c<br>
index 7f95ccb..b975485 100644<br>
--- a/bin/varnishd/cache/cache_<wbr>vrt.c<br>
+++ b/bin/varnishd/cache/cache_<wbr>vrt.c<br>
@@ -547,7 +547,7 @@ VRT_purge(VRT_CTX, double ttl, double grace, double keep)<br>
<br>
        CHECK_OBJ_NOTNULL(ctx, VRT_CTX_MAGIC);<br>
<br>
-       if (ctx->method != VCL_MET_HIT && ctx->method != VCL_MET_MISS) {<br>
+       if ((ctx->method & (VCL_MET_HIT|VCL_MET_MISS)) == 0) {<br>
                VSLb(ctx->vsl, SLT_VCL_Error,<br>
                    "purge can only happen in vcl_hit{} or vcl_miss{}");<br>
                VRT_handling(ctx, VCL_RET_FAIL);<br>
______________________________<wbr>_________________<br>
varnish-commit mailing list<br>
<a href="mailto:varnish-commit@varnish-cache.org">varnish-commit@varnish-cache.<wbr>org</a><br>
<a href="https://www.varnish-cache.org/lists/mailman/listinfo/varnish-commit" rel="noreferrer" target="_blank">https://www.varnish-cache.org/<wbr>lists/mailman/listinfo/<wbr>varnish-commit</a><br>
</blockquote></div><br></div>