nl8021: Avoid potential memory leak on error path
The called function nl80211_ht_vht_overrides() was not freeing "msg" resource in error cases. Signed-off-by: Purushottam Kushwaha <p.kushwaha@samsung.com>
This commit is contained in:
parent
c31302c038
commit
e15dcf6d1b
1 changed files with 3 additions and 2 deletions
|
@ -4549,8 +4549,9 @@ retry:
|
|||
goto fail;
|
||||
}
|
||||
|
||||
if (nl80211_ht_vht_overrides(msg, params) < 0)
|
||||
return -1;
|
||||
ret = nl80211_ht_vht_overrides(msg, params);
|
||||
if (ret < 0)
|
||||
goto fail;
|
||||
|
||||
ret = send_and_recv_msgs(drv, msg, NULL, NULL);
|
||||
msg = NULL;
|
||||
|
|
Loading…
Reference in a new issue