memif: memory leak when deleting memif interface
When deleting a memif interface, there is a memory leak in mif->local_disc_string. The code that leads to memory leak is memif_delete_if -> memif_disconect -> vec_dup Type: fix Signed-off-by: Steven Luong <sluong@cisco.com> Change-Id: I579c743c3d47770131153e083e65f6cd899067b3
This commit is contained in:

committed by
Damjan Marion

parent
a47203128b
commit
261a059b3d
@ -873,6 +873,7 @@ memif_delete_if (vlib_main_t * vm, memif_if_t * mif)
|
||||
}
|
||||
}
|
||||
|
||||
vec_free (mif->local_disc_string);
|
||||
clib_memset (mif, 0, sizeof (*mif));
|
||||
pool_put (mm->interfaces, mif);
|
||||
|
||||
|
Reference in New Issue
Block a user