Skip to content
Commit 05cd8238 authored by Li Zhong's avatar Li Zhong Committed by Jakub Kicinski
Browse files

ethtool: tunnels: check the return value of nla_nest_start()



Check the return value of nla_nest_start(). When starting the entry
level nested attributes, if the tailroom of socket buffer is
insufficient to store the attribute header and payload, the return value
will be NULL.

There is, however, no real bug here since if the skb is full
nla_put_be16() will fail as well and we'll error out.

Signed-off-by: default avatarLi Zhong <floridsleeves@gmail.com>
Link: https://lore.kernel.org/r/20220921181716.1629541-1-floridsleeves@gmail.com


Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent 97cfede0
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment