Commit 8169a601 authored by Yeounsu Moon's avatar Yeounsu Moon Committed by Jakub Kicinski
Browse files

net: dlink: handle copy_thresh allocation failure



The driver did not handle failure of `netdev_alloc_skb_ip_align()`.
If the allocation failed, dereferencing `skb->protocol` could lead to
a NULL pointer dereference.

This patch tries to allocate `skb`. If the allocation fails, it falls
back to the normal path.

Fixes: 1da177e4 ("Linux-2.6.12-rc2")
Suggested-by: default avatarJakub Kicinski <kuba@kernel.org>
Tested-on: D-Link DGE-550T Rev-A3
Signed-off-by: default avatarYeounsu Moon <yyyynoom@gmail.com>
Reviewed-by: default avatarAndrew Lunn <andrew@lunn.ch>
Link: https://patch.msgid.link/20250928190124.1156-1-yyyynoom@gmail.com


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