diff options
author | 2021-11-24 14:25:09 -0600 | |
---|---|---|
committer | 2021-11-25 19:37:34 -0800 | |
commit | 1b65bbcc9a71012003511b23b02b32db5c2f1adb (patch) | |
tree | d9773345fc1747bb90a540f129447bb5dab2822f /net/unix/af_unix.c | |
parent | net: ipa: explicitly disable HOLB drop during setup (diff) | |
download | wireguard-linux-1b65bbcc9a71012003511b23b02b32db5c2f1adb.tar.xz wireguard-linux-1b65bbcc9a71012003511b23b02b32db5c2f1adb.zip |
net: ipa: skip SKB copy if no netdev
In ipa_endpoint_skb_copy(), a new socket buffer structure is
allocated so that some data can be copied into it. However, after
doing this, if the endpoint has a null netdev pointer, we just drop
free the socket buffer.
Instead, check endpoint->netdev pointer first, and just return early
if it's null. Also return early if the SKB allocation fails, to
avoid the deeper indentation in the normal path.
Signed-off-by: Alex Elder <elder@linaro.org>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'net/unix/af_unix.c')
0 files changed, 0 insertions, 0 deletions