[master] 01ef5b2 (struct vsm).dname gets initialized in VSM_Open

Nils Goroll nils.goroll at uplex.de
Fri Jun 30 19:59:05 CEST 2017


commit 01ef5b28904b989ae7170a32205471163d984289
Author: Nils Goroll <nils.goroll at uplex.de>
Date:   Fri Jun 30 19:56:10 2017 +0200

    (struct vsm).dname gets initialized in VSM_Open
    
    Fixes #2359

diff --git a/lib/libvarnishapi/vsm.c b/lib/libvarnishapi/vsm.c
index 9261645..a92a84c 100644
--- a/lib/libvarnishapi/vsm.c
+++ b/lib/libvarnishapi/vsm.c
@@ -212,11 +212,11 @@ VSM_Start(struct vsm *vd, double patience, int progress)
 	int i, n = 0;
 
 	CHECK_OBJ_NOTNULL(vd, VSM_MAGIC);
-	AN(vd->dname);
 	t0 = VTIM_mono();
 	while (1) {
 		VSM_ResetError(vd);
 		i = VSM_Open(vd);
+		AN(vd->dname);
 		if (patience <= 0. || i == 0) {
 			if (progress >= 0 && n > 4)
 				(void)write(progress, "\n", 1);



More information about the varnish-commit mailing list