2
0
mirror of https://github.com/openvswitch/ovs synced 2025-08-31 14:25:26 +00:00

dpif-netdev: Fix cmap node use after free on flow disassociation.

Data pointed by cmap node must not be freed while iterating.
ovsrcu_postpone should be used instead.

CC: Finn Christensen <fc@napatech.com>
Fixes: e8a2b5bf92 ("netdev-dpdk: implement flow offload with rte flow")
Signed-off-by: Ilya Maximets <i.maximets@samsung.com>
Signed-off-by: Ian Stokes <ian.stokes@intel.com>
This commit is contained in:
Ilya Maximets
2018-10-19 16:51:13 +03:00
committed by Ian Stokes
parent 95ca79d542
commit 5752eae485
2 changed files with 2 additions and 2 deletions

View File

@@ -4043,7 +4043,7 @@ ufid_to_rte_flow_disassociate(const ovs_u128 *ufid) {
if (ovs_u128_equals(*ufid, data->ufid)) {
cmap_remove(&ufid_to_rte_flow,
CONST_CAST(struct cmap_node *, &data->node), hash);
free(data);
ovsrcu_postpone(free, data);
return;
}
}