lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20190522123206.GB24298@kroah.com>
Date:   Wed, 22 May 2019 14:32:07 +0200
From:   Greg Kroah-Hartman <gregkh@...uxfoundation.org>
To:     Hariprasad Kelam <hariprasad.kelam@...il.com>
Cc:     Anirudh Rayabharam <anirudh.rayabharam@...il.com>,
        Kimberly Brown <kimbrownkd@...il.com>,
        Nishka Dasgupta <nishka.dasgupta@...oo.com>,
        Murray McAllister <murray.mcallister@...omniasec.com>,
        Mamta Shukla <mamtashukla555@...il.com>,
        Hardik Singh Rathore <hardiksingh.k@...il.com>,
        Larry Finger <Larry.Finger@...inger.net>,
        Arnd Bergmann <arnd@...db.de>,
        Quytelda Kahja <quytelda@...alin.org>,
        Omer Efrat <omer.efrat@...demg.com>,
        Michael Straube <straube.linux@...il.com>,
        Emanuel Bennici <benniciemanuel78@...il.com>,
        Andy Shevchenko <andy.shevchenko@...il.com>,
        Jia-Ju Bai <baijiaju1990@...il.com>,
        Payal Kshirsagar <payal.s.kshirsagar.98@...il.com>,
        Wen Yang <wen.yang99@....com.cn>, devel@...verdev.osuosl.org,
        linux-kernel@...r.kernel.org
Subject: Re: [Patch v2] staging: rtl8723bs: core: rtw_ap: fix Unneeded
 variable: "ret". Return "0

On Wed, May 22, 2019 at 12:30:33AM +0530, Hariprasad Kelam wrote:
> Function "rtw_sta_flush" always returns 0 value.
> So change return type of rtw_sta_flush from int to void.
> 
> Same thing applies for rtw_hostapd_sta_flush
> 
> Signed-off-by: Hariprasad Kelam <hariprasad.kelam@...il.com>
> ------
> Changes v2 -
> 	change return type of rtw_sta_flush
> 
> -----
>  drivers/staging/rtl8723bs/core/rtw_ap.c           | 7 ++-----
>  drivers/staging/rtl8723bs/include/rtw_ap.h        | 2 +-
>  drivers/staging/rtl8723bs/os_dep/ioctl_cfg80211.c | 4 ++--
>  drivers/staging/rtl8723bs/os_dep/ioctl_linux.c    | 7 +++----
>  4 files changed, 8 insertions(+), 12 deletions(-)
> 
> diff --git a/drivers/staging/rtl8723bs/core/rtw_ap.c b/drivers/staging/rtl8723bs/core/rtw_ap.c
> index bc02306..19418ea 100644
> --- a/drivers/staging/rtl8723bs/core/rtw_ap.c
> +++ b/drivers/staging/rtl8723bs/core/rtw_ap.c
> @@ -2189,10 +2189,9 @@ u8 ap_free_sta(
>  	return beacon_updated;
>  }
>  
> -int rtw_sta_flush(struct adapter *padapter)
> +void rtw_sta_flush(struct adapter *padapter)
>  {
>  	struct list_head	*phead, *plist;
> -	int ret = 0;
>  	struct sta_info *psta = NULL;
>  	struct sta_priv *pstapriv = &padapter->stapriv;
>  	struct mlme_ext_priv *pmlmeext = &padapter->mlmeextpriv;
> @@ -2202,7 +2201,7 @@ int rtw_sta_flush(struct adapter *padapter)
>  	DBG_871X(FUNC_NDEV_FMT"\n", FUNC_NDEV_ARG(padapter->pnetdev));
>  
>  	if ((pmlmeinfo->state&0x03) != WIFI_FW_AP_STATE)
> -		return ret;
> +		return ;

Odd use of a ' ' character here :(

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ