summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorNeale Ranns <nranns@cisco.com>2017-02-24 01:34:14 -0800
committerFlorin Coras <florin.coras@gmail.com>2017-02-24 11:16:25 +0000
commitbcc6aa4c13efef5684f80f59b4ef568ffeef2d9d (patch)
treecd409741858666e6d9ca164be5eac06f4c7fb068 /src
parent04197eea69c77a0145dc54d56fc767a03897c90e (diff)
MFIB memory leak. free the per-source interface hash
Change-Id: I0ccb337eb0ed50ccc64193533cd816f6e36e6db5 Signed-off-by: Neale Ranns <nranns@cisco.com>
Diffstat (limited to 'src')
-rw-r--r--src/vnet/fib/mpls_fib.c2
-rw-r--r--src/vnet/mfib/mfib_entry.c2
-rw-r--r--src/vppinfra/hash.h5
3 files changed, 3 insertions, 6 deletions
diff --git a/src/vnet/fib/mpls_fib.c b/src/vnet/fib/mpls_fib.c
index cc657975d0f..5cd0fd23f92 100644
--- a/src/vnet/fib/mpls_fib.c
+++ b/src/vnet/fib/mpls_fib.c
@@ -272,7 +272,7 @@ mpls_fib_table_destroy (mpls_fib_t *mf)
hash_unset(mpls_main.fib_index_by_table_id,
fib_table->ft_table_id);
}
- hash_delete(mf->mf_entries);
+ hash_free(mf->mf_entries);
pool_put(mpls_main.fibs, fib_table);
}
diff --git a/src/vnet/mfib/mfib_entry.c b/src/vnet/mfib/mfib_entry.c
index 1947360ad14..117ddc2fdfd 100644
--- a/src/vnet/mfib/mfib_entry.c
+++ b/src/vnet/mfib/mfib_entry.c
@@ -292,6 +292,8 @@ mfib_entry_src_flush (mfib_entry_src_t *msrc)
({
mfib_itf_delete(mfib_itf_get(mfii));
}));
+ hash_free(msrc->mfes_itfs);
+ msrc->mfes_itfs = NULL;
fib_path_list_unlock(msrc->mfes_pl);
}
diff --git a/src/vppinfra/hash.h b/src/vppinfra/hash.h
index 3f0efaa727c..4db5a57602e 100644
--- a/src/vppinfra/hash.h
+++ b/src/vppinfra/hash.h
@@ -683,11 +683,6 @@ unformat_function_t unformat_hash_string;
/* Main test routine. */
int test_hash_main (unformat_input_t * input);
-static inline void
-hash_delete (void *bob)
-{
-}
-
#endif /* included_hash_h */
/*