mirror of https://gitee.com/openkylin/linux.git
wil6210: Delete an unnecessary kfree() call in wil_tid_ampdu_rx_alloc()
A null pointer would be passed to a call of the function “kfree” directly after a call of the function “kcalloc” failed at one place. Remove this superfluous function call. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Reviewed-by: Maya Erez <merez@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
This commit is contained in:
parent
9abe3e306e
commit
d20b1e6c83
|
@ -260,7 +260,6 @@ struct wil_tid_ampdu_rx *wil_tid_ampdu_rx_alloc(struct wil6210_priv *wil,
|
|||
r->reorder_buf =
|
||||
kcalloc(size, sizeof(struct sk_buff *), GFP_KERNEL);
|
||||
if (!r->reorder_buf) {
|
||||
kfree(r->reorder_buf);
|
||||
kfree(r);
|
||||
return NULL;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue