Fix buffer leak from L2 flooding replication process 24/1824/2
authorPierre Pfister <ppfister@cisco.com>
Thu, 30 Jun 2016 13:06:55 +0000 (14:06 +0100)
committerDave Barach <openvpp@barachs.net>
Thu, 30 Jun 2016 14:15:52 +0000 (14:15 +0000)
commit371fa4411048c4f34a3f35dc0398e1b01c6928cd
tree6ec5d82648fac27e2101cd39396ee3e92a0469af
parentc4770ecc622e815bd6f355aea0bedfe38820c757
Fix buffer leak from L2 flooding replication process

vlib_buffer_free_inline actually checks (b->flags & VLIB_BUFFER_RECYCLE)
in order to decide whether to free the packet or not.
Although the flag was correctly set in replication_prep, it is not removed
by replication_recycle during last iteration.

This patch just removes VLIB_BUFFER_RECYCLE when is_last is set.

Change-Id: I2445ebce908d94d95535e706b40407b4f15906e4
Signed-off-by: Pierre Pfister <ppfister@cisco.com>
vnet/vnet/replication.c