[6.0] 7d1189bd4 Sync with VTEST
Dridi Boukelmoune
dridi.boukelmoune at gmail.com
Wed Jul 10 07:42:09 UTC 2019
commit 7d1189bd4a76fc662425c8bb68db9f0d36a6f395
Author: Poul-Henning Kamp <phk at FreeBSD.org>
Date: Tue Jan 15 13:45:27 2019 +0000
Sync with VTEST
diff --git a/bin/varnishtest/vtc_haproxy.c b/bin/varnishtest/vtc_haproxy.c
index 0ff037f6d..f8e973701 100644
--- a/bin/varnishtest/vtc_haproxy.c
+++ b/bin/varnishtest/vtc_haproxy.c
@@ -481,7 +481,7 @@ haproxy_new(const char *name)
h->cli = haproxy_cli_new(h);
AN(h->cli);
- bprintf(buf, "rm -rf %s ; mkdir -p %s", h->workdir, h->workdir);
+ bprintf(buf, "rm -rf \"%s\" ; mkdir -p \"%s\"", h->workdir, h->workdir);
AZ(system(buf));
VTAILQ_INSERT_TAIL(&haproxies, h, list);
@@ -502,7 +502,7 @@ haproxy_delete(struct haproxy *h)
vtc_logclose(h->vl);
if (!leave_temp) {
- bprintf(buf, "rm -rf %s", h->workdir);
+ bprintf(buf, "rm -rf \"%s\"", h->workdir);
AZ(system(buf));
}
@@ -552,7 +552,7 @@ haproxy_start(struct haproxy *h)
vsb = VSB_new_auto();
AN(vsb);
- VSB_printf(vsb, "exec %s", h->filename);
+ VSB_printf(vsb, "exec \"%s\"", h->filename);
if (h->opt_check_mode)
VSB_printf(vsb, " -c");
else if (h->opt_daemon)
@@ -565,13 +565,13 @@ haproxy_start(struct haproxy *h)
VSB_printf(vsb, " %s", VSB_data(h->args));
- VSB_printf(vsb, " -f %s ", h->cfg_fn);
+ VSB_printf(vsb, " -f \"%s\" ", h->cfg_fn);
if (h->opt_worker || h->opt_daemon) {
bprintf(buf, "%s/pid", h->workdir);
h->pid_fn = strdup(buf);
AN(h->pid_fn);
- VSB_printf(vsb, " -p %s", h->pid_fn);
+ VSB_printf(vsb, " -p \"%s\"", h->pid_fn);
}
AZ(VSB_finish(vsb));
@@ -758,7 +758,7 @@ haproxy_write_conf(const struct haproxy *h, const char *cfg, int auto_be)
vsb2 = VSB_new_auto();
AN(vsb2);
- VSB_printf(vsb, " global\n\tstats socket %s "
+ VSB_printf(vsb, " global\n\tstats socket \"%s\" "
"level admin mode 600\n", h->cli_fn);
VSB_printf(vsb, " stats socket \"fd@${cli}\" level admin\n");
AZ(VSB_cat(vsb, cfg));
diff --git a/bin/varnishtest/vtc_http.c b/bin/varnishtest/vtc_http.c
index 03aa7f7e5..616cb459e 100644
--- a/bin/varnishtest/vtc_http.c
+++ b/bin/varnishtest/vtc_http.c
@@ -797,8 +797,11 @@ cmd_http_gunzip(CMD_ARGS)
static void
gzip_body(const struct http *hp, const char *txt, char **body, int *bodylen)
{
- int l, i;
+ int l;
z_stream vz;
+#ifdef VGZ_EXTENSIONS
+ int i;
+#endif
memset(&vz, 0, sizeof vz);
More information about the varnish-commit
mailing list