MINOR: tree-wide: use free_acl_cond() where relevant
Now that we have free_acl_cond(cond) function that does cond prune then
frees cond, replace all occurences of this pattern:
| prune_acl_cond(cond)
| free(cond)
with:
| free_acl_cond(cond)
diff --git a/src/http_rules.c b/src/http_rules.c
index 1efba4a..192f0c7 100644
--- a/src/http_rules.c
+++ b/src/http_rules.c
@@ -322,10 +322,7 @@
{
struct logformat_node *lf, *lfb;
- if (rdr->cond) {
- prune_acl_cond(rdr->cond);
- free(rdr->cond);
- }
+ free_acl_cond(rdr->cond);
free(rdr->rdr_str);
free(rdr->cookie_str);
list_for_each_entry_safe(lf, lfb, &rdr->rdr_fmt, list) {
@@ -519,8 +516,7 @@
http_free_redirect_rule(rule);
else if (cond) {
/* rule not yet allocated, but cond already is */
- prune_acl_cond(cond);
- free(cond);
+ free_acl_cond(cond);
}
return NULL;