[MINOR] config: don't accept 'appsession' in defaults section

Maybe appsession should be forbidden in the 'defaults' section as it
will not work in the backends.
This commit is contained in:
Cyril Bont 2010-01-10 17:01:47 +01:00 committed by Willy Tarreau
parent b16a5746b7
commit 3b7a369baa

View File

@ -1580,6 +1580,12 @@ int cfg_parse_listen(const char *file, int linenum, char **args, int kwm)
else if (!strcmp(args[0], "appsession")) { /* cookie name */
int cur_arg;
if (curproxy == &defproxy) {
Alert("parsing [%s:%d] : '%s' not allowed in 'defaults' section.\n", file, linenum, args[0]);
err_code |= ERR_ALERT | ERR_FATAL;
goto out;
}
if (warnifnotcap(curproxy, PR_CAP_BE, file, linenum, args[0], NULL))
err_code |= ERR_WARN;