Search Linux Wireless

Re: [patch] mac80211: unlock on error path in ieee80211_ibss_join()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 2011-12-08 at 09:49 +0300, Dan Carpenter wrote:
> We recently introduced a new return here but it needs an unlock first.

Thanks Dan! Bad Alex :-)

> Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
> 
> diff --git a/net/mac80211/ibss.c b/net/mac80211/ibss.c
> index 3f830ac..0fc9752 100644
> --- a/net/mac80211/ibss.c
> +++ b/net/mac80211/ibss.c
> @@ -993,8 +993,10 @@ int ieee80211_ibss_join(struct ieee80211_sub_if_data *sdata,
>  	if (params->channel_fixed) {
>  		sdata->local->oper_channel = params->channel;
>  		if (!ieee80211_set_channel_type(sdata->local, sdata,
> -					       params->channel_type))
> +					       params->channel_type)) {
> +			mutex_unlock(&sdata->u.ibss.mtx);
>  			return -EINVAL;
> +		}
>  	}
>  
>  	if (params->ie) {
> 


--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux