提交 d9e0ecb8 编写于 作者: A Andy Zhou 提交者: Pravin B Shelar

openvswitch: Add skb_clone NULL check for the sampling action.

Fix a bug where skb_clone() NULL check is missing in sample action
implementation.
Signed-off-by: NAndy Zhou <azhou@nicira.com>
Signed-off-by: NPravin B Shelar <pshelar@nicira.com>
上级 651887b0
......@@ -477,6 +477,8 @@ static int sample(struct datapath *dp, struct sk_buff *skb,
skb_get(skb);
} else {
sample_skb = skb_clone(skb, GFP_ATOMIC);
if (!sample_skb) /* Skip sample action when out of memory. */
return 0;
}
/* Note that do_execute_actions() never consumes skb.
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册