From 345047be5b8766a9763d4a717ff034e4e4083ade Mon Sep 17 00:00:00 2001 From: Tavian Barnes Date: Thu, 31 Aug 2023 10:16:35 -0400 Subject: trie: New trie_clear() function --- src/color.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/color.c') diff --git a/src/color.c b/src/color.c index f7a5d86..b9a788b 100644 --- a/src/color.c +++ b/src/color.c @@ -326,8 +326,7 @@ fail: /** Rebuild the case-insensitive trie after all extensions have been parsed. */ static int build_iext_trie(struct colors *colors) { - trie_destroy(&colors->iext_trie); - trie_init(&colors->iext_trie); + trie_clear(&colors->iext_trie); TRIE_FOR_EACH(&colors->ext_trie, leaf) { size_t len = leaf->length - 1; -- cgit v1.2.3