OSDN Git Service

netfilter: nft_tunnel: add the missing nla_nest_cancel()
authorXin Long <lucien.xin@gmail.com>
Fri, 13 Dec 2019 08:53:09 +0000 (16:53 +0800)
committerPablo Neira Ayuso <pablo@netfilter.org>
Tue, 17 Dec 2019 21:58:28 +0000 (22:58 +0100)
commit7e03998429ee0a27c13b8690c11f9cf40f67f6e9
tree865d476d59407494c68ddd1476021bf6cfba9114
parent73239bd9707ab2f3b7621e50468c14410cf4e2c2
netfilter: nft_tunnel: add the missing nla_nest_cancel()

When nla_put_xxx() fails under nla_nest_start_noflag(),
nla_nest_cancel() should be called, so that the skb can
be trimmed properly.

Signed-off-by: Xin Long <lucien.xin@gmail.com>
Reviewed-by: Simon Horman <simon.horman@netronome.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
net/netfilter/nft_tunnel.c