[6.0] 32a56bba5 Pass -j args to child

Dridi Boukelmoune dridi.boukelmoune at gmail.com
Thu Aug 16 08:52:57 UTC 2018


commit 32a56bba5f218b20849c2cd2ce9c5cb81032350f
Author: Poul-Henning Kamp <phk at FreeBSD.org>
Date:   Sun May 13 15:09:04 2018 +0000

    Pass -j args to child

diff --git a/bin/varnishd/mgt/mgt_cli.c b/bin/varnishd/mgt/mgt_cli.c
index bc9c2a78f..3304ef03c 100644
--- a/bin/varnishd/mgt/mgt_cli.c
+++ b/bin/varnishd/mgt/mgt_cli.c
@@ -162,10 +162,10 @@ mcf_askchild(struct cli *cli, const char * const *av, void *priv)
 }
 
 static const struct cli_cmd_desc CLICMD_WILDCARD[1] =
-    {{ "*", "<wild-card-entry>", "<fall through to cacher>", "", 0, -1 }};
+    {{ "*", "<wild-card-entry>", "<fall through to cacher>", "", 0, 999 }};
 
 static struct cli_proto cli_askchild[] = {
-	{ CLICMD_WILDCARD, "h*", mcf_askchild },
+	{ CLICMD_WILDCARD, "h*", mcf_askchild, mcf_askchild },
 	{ NULL }
 };
 
diff --git a/lib/libvarnish/vcli_serve.c b/lib/libvarnish/vcli_serve.c
index a5e671490..67c681642 100644
--- a/lib/libvarnish/vcli_serve.c
+++ b/lib/libvarnish/vcli_serve.c
@@ -215,7 +215,7 @@ cls_dispatch(struct cli *cli, const struct cli_proto *cp,
 		return;
 	}
 
-	if (ac - 1> cp->desc->maxarg + json) {
+	if (ac - 1 > cp->desc->maxarg + json) {
 		VCLI_Out(cli, "Too many parameters\n");
 		VCLI_SetResult(cli, CLIS_TOOMANY);
 		return;


More information about the varnish-commit mailing list