session: fix use-after-free
Type: fix
Change-Id: Ie63b80db56febc8a16bafcdd5399b2f92b6aa437
Signed-off-by: Benoît Ganne <bganne@cisco.com>
diff --git a/src/vnet/session/mma_template.c b/src/vnet/session/mma_template.c
index e66f291..ae730e5 100644
--- a/src/vnet/session/mma_template.c
+++ b/src/vnet/session/mma_template.c
@@ -60,8 +60,8 @@
RTT (mma_rule) *
RT (mma_rule_free) (RTT (mma_rules_table) * srt, RTT (mma_rule) * rule)
{
- pool_put (srt->rules, rule);
clib_memset (rule, 0xfa, sizeof (*rule));
+ pool_put (srt->rules, rule);
return rule;
}