summaryrefslogtreecommitdiff
path: root/filter
diff options
context:
space:
mode:
authorOndrej Zajicek (work) <santiago@crfreenet.org>2020-11-24 04:09:11 +0100
committerOndrej Zajicek (work) <santiago@crfreenet.org>2020-11-24 04:09:11 +0100
commit30b846826905b4da76f59a212a31928bd55e9783 (patch)
treeb8dcc75f7e76a71df397ed240e826fdefaebf0fb /filter
parent1678bc07467e6d977fc2f6bf830274ca92e0a6e5 (diff)
Minor cleanups with cfg_allocz()
Also fixes some more failed asserts due to add_tail().
Diffstat (limited to 'filter')
-rw-r--r--filter/tree.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/filter/tree.c b/filter/tree.c
index 46d6e529..2bbc84bb 100644
--- a/filter/tree.c
+++ b/filter/tree.c
@@ -103,12 +103,7 @@ build_tree(struct f_tree *from)
struct f_tree *
f_new_tree(void)
{
- struct f_tree * ret;
- ret = cfg_alloc(sizeof(struct f_tree));
- ret->left = ret->right = NULL;
- ret->from.type = ret->to.type = T_VOID;
- ret->from.val.i = ret->to.val.i = 0;
- ret->data = NULL;
+ struct f_tree *ret = cfg_allocz(sizeof(struct f_tree));
return ret;
}