]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
CLEANUP: acl: Remove unused variable when releasing an acl expression
authorChristopher Faulet <cfaulet@haproxy.com>
Fri, 10 Sep 2021 13:17:45 +0000 (15:17 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Thu, 16 Sep 2021 06:31:46 +0000 (08:31 +0200)
The "unresolved" variable is unused since commit 9fa0df5 ("BUG/MINOR: acl:
Fix freeing of expr->smp in prune_acl_expr").

This patch should fix the issue #1359.

src/acl.c

index 193788c5064a25ff1d24ead89f6d71fc0bdd7ee9..b2b0f0c1cf60e8869187e6f0a5c7e3fe89b20b43 100644 (file)
--- a/src/acl.c
+++ b/src/acl.c
@@ -101,7 +101,6 @@ struct acl_keyword *find_acl_kw(const char *kw)
 static struct acl_expr *prune_acl_expr(struct acl_expr *expr)
 {
        struct arg *arg;
-       int unresolved = 0;
 
        pattern_prune(&expr->pat);
 
@@ -110,7 +109,6 @@ static struct acl_expr *prune_acl_expr(struct acl_expr *expr)
                        break;
                if (arg->type == ARGT_STR || arg->unresolved) {
                        chunk_destroy(&arg->data.str);
-                       unresolved |= arg->unresolved;
                        arg->unresolved = 0;
                }
        }