Storage pointed to by gen_ie is allocated with kmalloc, but was
never freed.
Coverity CID #1271251
Signed-off-by: John W. Linville <[email protected]>
---
drivers/net/wireless/mwifiex/ie.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/net/wireless/mwifiex/ie.c b/drivers/net/wireless/mwifiex/ie.c
index 23e368c77c08..abf52d25b981 100644
--- a/drivers/net/wireless/mwifiex/ie.c
+++ b/drivers/net/wireless/mwifiex/ie.c
@@ -479,6 +479,7 @@ int mwifiex_del_mgmt_ies(struct mwifiex_private *priv)
ar_ie, &priv->assocresp_idx);
done:
+ kfree(gen_ie);
kfree(beacon_ie);
kfree(pr_ie);
kfree(ar_ie);
--
2.1.0
> Storage pointed to by gen_ie is allocated with kmalloc, but was
> never freed.
>
> Coverity CID #1271251
>
> Signed-off-by: John W. Linville <[email protected]>
> Acked-by: Amitkumar Karwar <[email protected]>
Thanks, applied to wireless-drivers-next.git.
Kalle Valo
Hi John,
> From: John W. Linville [mailto:[email protected]]
> Sent: Saturday, June 27, 2015 1:00 AM
> To: [email protected]
> Cc: Amitkumar Karwar; Nishant Sarmukadam; Kalle Valo; John W. Linville
> Subject: [PATCH] mwifiex: fix leak of gen_ie storage on exit from
> mwifiex_del_mgmt_ies
>
> Storage pointed to by gen_ie is allocated with kmalloc, but was never
> freed.
>
> Coverity CID #1271251
>
> Signed-off-by: John W. Linville <[email protected]>
Acked-by: Amitkumar Karwar <[email protected]>
Regards,
Amitkumar