From 5a5f49111e88e609fdaac36d80e6f75b8f8f332c Mon Sep 17 00:00:00 2001 From: Piotr Sikora Date: Wed, 18 Jul 2018 19:14:38 +0000 Subject: [PATCH] lc trie: fix memory leak. *Risk Level*: Low *Testing*: curl -s 127.0.0.1:/stats | grep server.memory *Docs Changes*: n/a *Release Notes*: n/a Signed-off-by: Piotr Sikora --- source/common/network/lc_trie.h | 1 + 1 file changed, 1 insertion(+) diff --git a/source/common/network/lc_trie.h b/source/common/network/lc_trie.h index bd9109491a0d0..3670eedd7c338 100644 --- a/source/common/network/lc_trie.h +++ b/source/common/network/lc_trie.h @@ -459,6 +459,7 @@ template class LcTrie { // The value of next_free_index is the final size of the trie_. trie_.resize(next_free_index); + trie_.shrink_to_fit(); } // Thin wrapper around computeBranch output to facilitate code readability.