Commit bcfc82eb authored by Poul-Henning Kamp's avatar Poul-Henning Kamp

Polish error messages a bit.

parent 2afa4c66
......@@ -589,17 +589,26 @@ main(int argc, char * const *argv)
if (x_arg != NULL) {
if (argc != 3)
ARGV_ERR("-x is incompatible all options/arguments\n");
ARGV_ERR("-x is incompatible with everything else\n");
mgt_x_arg(x_arg);
exit(0);
}
if (b_arg != NULL && f_arg != NULL)
ARGV_ERR("Only one of -b or -f can be specified\n");
if (d_flag && F_flag)
ARGV_ERR("Only one of -d or -F can be specified\n");
if (C_flag && b_arg == NULL && f_arg == NULL)
ARGV_ERR("-C only good with -b or -f\n");
if (b_arg != NULL && f_arg != NULL)
ARGV_ERR("Only one of -b or -f can be specified\n");
ARGV_ERR("-C needs either -b <backend> or -f <vcl_file>\n");
if (d_flag && C_flag)
ARGV_ERR("-d makes no sense with -C\n");
if (F_flag && C_flag)
ARGV_ERR("-F makes no sense with -C\n");
/* Set up the mgt counters */
memset(&static_VSC_C_mgt, 0, sizeof static_VSC_C_mgt);
......
......@@ -8,9 +8,11 @@ err_shell {VCL version declaration missing} "echo 'bad vcl' >${tmpdir}/t.vcl ; v
err_shell {VCL version declaration missing} "echo 'bad vcl' >${tmpdir}/t.vcl ; varnishd -C -f ${tmpdir}/t.vcl -n ${tmpdir} 2>&1"
err_shell {-spersistent has been deprecated} "varnishd -spersistent 2>&1"
err_shell {Unknown jail method "xyz"} "varnishd -jxyz 2>&1"
err_shell {-x is incompatible all options/arguments} "varnishd -d -x foo 2>&1"
err_shell {-x is incompatible with everything else} "varnishd -d -x foo 2>&1"
err_shell {Invalid -x argument} "varnishd -x foo 2>&1"
err_shell {Too many arguments} "varnishd foo 2>&1"
err_shell {Only one of -d or -F can be specified} "varnishd -d -F 2>&1"
err_shell {Only one of -b or -f can be specified} "varnishd -b a -f b 2>&1"
err_shell {-C only good with -b or -f} "varnishd -C 2>&1"
err_shell {-C needs either -b <backend> or -f <vcl_file>} "varnishd -C 2>&1"
err_shell {-d makes no sense with -C} "varnishd -C -b 127.0.0.1:80 -d 2>&1"
err_shell {-F makes no sense with -C} "varnishd -C -b 127.0.0.1:80 -F 2>&1"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment