Commit cc6528b
r8169: fix potential skb double free in an error path
The caller of rtl8169_tso_csum_v2() frees the skb if false is returned.
eth_skb_pad() internally frees the skb on error what would result in a
double free. Therefore use __skb_put_padto() directly and instruct it
to not free the skb on error.
Fixes: b423e9a ("r8169: fix offloaded tx checksum for small packets.")
Reported-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Link: https://lore.kernel.org/r/f7e68191-acff-9ded-4263-c016428a8762@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>1 parent 86bbf01 commit cc6528b
1 file changed
Lines changed: 2 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4163 | 4163 | | |
4164 | 4164 | | |
4165 | 4165 | | |
4166 | | - | |
| 4166 | + | |
| 4167 | + | |
4167 | 4168 | | |
4168 | 4169 | | |
4169 | 4170 | | |
| |||
0 commit comments