[master] 98f55dae5 vep->state == VEP_MATCH implies vep->match != NULL

Nils Goroll nils.goroll at uplex.de
Mon Dec 28 15:22:08 UTC 2020


commit 98f55dae5f3e38358a5a06ecd6c492b897203fac
Author: Nils Goroll <nils.goroll at uplex.de>
Date:   Mon Dec 28 15:47:35 2020 +0100

    vep->state == VEP_MATCH implies vep->match != NULL
    
    Coverity CID 1099620

diff --git a/bin/varnishd/cache/cache_esi_parse.c b/bin/varnishd/cache/cache_esi_parse.c
index 995087aa5..0bda28c84 100644
--- a/bin/varnishd/cache/cache_esi_parse.c
+++ b/bin/varnishd/cache/cache_esi_parse.c
@@ -225,6 +225,7 @@ vep_match(const struct vep_state *vep, const char *b, const char *e)
 	struct vep_match *vm;
 	const char *q, *r;
 
+	AN(vep->match);
 	for (vm = vep->match; vm->match != NULL; vm++) {
 		assert(strlen(vm->match) <= sizeof (vep->tag));
 		r = b;


More information about the varnish-commit mailing list