Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
varnish-cache
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
varnishcache
varnish-cache
Commits
bcfc82eb
Commit
bcfc82eb
authored
Dec 22, 2016
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Polish error messages a bit.
parent
2afa4c66
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
6 deletions
+17
-6
mgt_main.c
bin/varnishd/mgt/mgt_main.c
+13
-4
a00009.vtc
bin/varnishtest/tests/a00009.vtc
+4
-2
No files found.
bin/varnishd/mgt/mgt_main.c
View file @
bcfc82eb
...
@@ -589,17 +589,26 @@ main(int argc, char * const *argv)
...
@@ -589,17 +589,26 @@ main(int argc, char * const *argv)
if
(
x_arg
!=
NULL
)
{
if
(
x_arg
!=
NULL
)
{
if
(
argc
!=
3
)
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
);
mgt_x_arg
(
x_arg
);
exit
(
0
);
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
)
if
(
d_flag
&&
F_flag
)
ARGV_ERR
(
"Only one of -d or -F can be specified
\n
"
);
ARGV_ERR
(
"Only one of -d or -F can be specified
\n
"
);
if
(
C_flag
&&
b_arg
==
NULL
&&
f_arg
==
NULL
)
if
(
C_flag
&&
b_arg
==
NULL
&&
f_arg
==
NULL
)
ARGV_ERR
(
"-C only good with -b or -f
\n
"
);
ARGV_ERR
(
"-C needs either -b <backend> or -f <vcl_file>
\n
"
);
if
(
b_arg
!=
NULL
&&
f_arg
!=
NULL
)
ARGV_ERR
(
"Only one of -b or -f can be specified
\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 */
/* Set up the mgt counters */
memset
(
&
static_VSC_C_mgt
,
0
,
sizeof
static_VSC_C_mgt
);
memset
(
&
static_VSC_C_mgt
,
0
,
sizeof
static_VSC_C_mgt
);
...
...
bin/varnishtest/tests/a00009.vtc
View file @
bcfc82eb
...
@@ -8,9 +8,11 @@ err_shell {VCL version declaration missing} "echo 'bad vcl' >${tmpdir}/t.vcl ; v
...
@@ -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 {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 {-spersistent has been deprecated} "varnishd -spersistent 2>&1"
err_shell {Unknown jail method "xyz"} "varnishd -jxyz 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 {Invalid -x argument} "varnishd -x foo 2>&1"
err_shell {Too many arguments} "varnishd 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 -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 {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"
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment