]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
[MINOR] config: report "default-server" instead of "(null)" in error messages
authorWilly Tarreau <w@1wt.eu>
Wed, 7 Apr 2010 14:06:40 +0000 (16:06 +0200)
committerWilly Tarreau <w@1wt.eu>
Wed, 7 Apr 2010 14:06:40 +0000 (16:06 +0200)
When an error is reported in a default-server entry, we want to have
that name in the error message instead of "(null)".

src/cfgparse.c

index dca5e6c57ec8bbd4eed1e063d621223ddcba46dd..f25cc76ee4c1b965fdf3c0f82fa89b5a0a2d005d 100644 (file)
@@ -1118,6 +1118,7 @@ int cfg_parse_listen(const char *file, int linenum, char **args, int kwm)
 
                /* set default values */
                memcpy(&curproxy->defsrv, &defproxy.defsrv, sizeof(curproxy->defsrv));
+               curproxy->defsrv.id = "default-server";
 
                curproxy->state = defproxy.state;
                curproxy->options = defproxy.options;