From 4fc09693d6f466ddf6b0721b20841d056759755a Mon Sep 17 00:00:00 2001 From: William Lallemand Date: Mon, 19 Jun 2017 16:37:19 +0200 Subject: [PATCH] MINOR: warning on multiple -x Multiple use of the -x option is useless, emit a warning. --- src/haproxy.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/haproxy.c b/src/haproxy.c index 2fd387f..1eabb55 100644 --- a/src/haproxy.c +++ b/src/haproxy.c @@ -1283,7 +1283,10 @@ static void init(int argc, char **argv) Alert("Unix socket path expected with the -x flag\n\n"); usage(progname); } + if (old_unixsocket) + Warning("-x option already set, overwriting the value\n"); old_unixsocket = argv[1]; + argv++; argc--; } -- 1.7.10.4