From: Willy Tarreau Date: Fri, 19 Oct 2012 14:47:23 +0000 (+0200) Subject: MINOR: sample: accept fetch keywords without parenthesis X-Git-Tag: v1.5-dev13~134 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=f22a50836def254c778278f3f231fd77e853e886;p=thirdparty%2Fhaproxy.git MINOR: sample: accept fetch keywords without parenthesis fetch keywords which support arguments do not support being called without parenthesis even if all arguments are optional. Let's fix this to allow fetch keywords without parenthesis as is already done in ACLs. --- diff --git a/src/sample.c b/src/sample.c index 3703a44b46..3e0c96501a 100644 --- a/src/sample.c +++ b/src/sample.c @@ -354,7 +354,7 @@ struct sample_expr *sample_parse_expr(char **str, int *idx, char *err, int err_s goto out_error; } } - else if (fetch->arg_mask) { + else if (ARGM(fetch->arg_mask)) { p = my_strndup(str[*idx], endw - str[*idx]); if (p) { snprintf(err, err_size, "missing args for fetch method '%s'.", p);