From: Bhumika Goyal Date: Mon, 15 Feb 2016 08:58:20 +0000 (+0530) Subject: Staging: rtl8188eu: core: rtw_mlme.c: Remove NULL test before vfree X-Git-Tag: v4.6-rc1~103^2~660 X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=commitdiff_plain;h=64e6619fd3f6c239d5f57f2c88fe9b9291a7e0f2;p=linux.git Staging: rtl8188eu: core: rtw_mlme.c: Remove NULL test before vfree The function vfree tests whether the argument is NULL and returns immediately. So NULL test before vfree is not needed. Also remove braces around if branch as they are no longer needed. Signed-off-by: Bhumika Goyal Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/rtl8188eu/core/rtw_mlme.c b/drivers/staging/rtl8188eu/core/rtw_mlme.c index 9c2e65904c0f..a645a620ebe2 100644 --- a/drivers/staging/rtl8188eu/core/rtw_mlme.c +++ b/drivers/staging/rtl8188eu/core/rtw_mlme.c @@ -122,10 +122,8 @@ void rtw_free_mlme_priv(struct mlme_priv *pmlmepriv) { rtw_free_mlme_priv_ie_data(pmlmepriv); - if (pmlmepriv) { - if (pmlmepriv->free_bss_buf) - vfree(pmlmepriv->free_bss_buf); - } + if (pmlmepriv) + vfree(pmlmepriv->free_bss_buf); } struct wlan_network *_rtw_alloc_network(struct mlme_priv *pmlmepriv)