Search Linux Wireless

Re: [PATCH] wireless: Remove spurious warning in mlme.c

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

 



On Tue, Dec 7, 2010 at 11:06 PM,  <greearb@xxxxxxxxxxxxxxx> wrote:
> From: Ben Greear <greearb@xxxxxxxxxxxxxxx>
>
> Seems that we should not be warning if all of the
> authtry_bsses are already NULL.
>
> Signed-off-by: Ben Greear <greearb@xxxxxxxxxxxxxxx>
> ---
> :100644 100644 d7680f2... 866d016... M  net/wireless/mlme.c
>  net/wireless/mlme.c |    5 +++--
>  1 files changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/net/wireless/mlme.c b/net/wireless/mlme.c
> index d7680f2..866d016 100644
> --- a/net/wireless/mlme.c
> +++ b/net/wireless/mlme.c
> @@ -266,7 +266,7 @@ EXPORT_SYMBOL(cfg80211_send_disassoc);
>  static void __cfg80211_auth_remove(struct wireless_dev *wdev, const u8 *addr)
>  {
>        int i;
> -       bool done = false;
> +       bool done = true;
>
>        ASSERT_WDEV_LOCK(wdev);
>
> @@ -277,9 +277,10 @@ static void __cfg80211_auth_remove(struct wireless_dev *wdev, const u8 *addr)
>                        cfg80211_unhold_bss(wdev->authtry_bsses[i]);
>                        cfg80211_put_bss(&wdev->authtry_bsses[i]->pub);
>                        wdev->authtry_bsses[i] = NULL;
> -                       done = true;
>                        break;
>                }
> +               else if (wdev->authtry_bsses[i])
> +                       done = false;

Coding style issues: always put the else on the same line as the
closing brace, and if one branch is braced, both branches should be
so.

>        }
>
>        WARN_ON(!done);
> --
> 1.7.2.3
>
> --
> 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
>



-- 
Vista: [V]iruses, [I]ntruders, [S]pyware, [T]rojans and [A]dware. :-)
--
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