From: Greg KH <gregkh@linuxfoundation.org>
To: Sanjana Sanikommu <sanjana99reddy99@gmail.com>
Cc: outreachy-kernel@googlegroups.com
Subject: Re: [PATCH] Staging: rtl8188eu: core: rtw_mlme.c: Fix unbalanced braces around else.
Date: Mon, 18 Mar 2019 14:55:21 +0100 [thread overview]
Message-ID: <20190318135521.GA7342@kroah.com> (raw)
In-Reply-To: <20190318125918.13149-1-sanjana99reddy99@gmail.com>
On Mon, Mar 18, 2019 at 06:29:18PM +0530, Sanjana Sanikommu wrote:
> Fix unbalanced braces after else statement.
> Issue found by checkpatch.pl semantic patch results for rtw_mlme.c
>
> CHECK: Unbalanced braces around else statement.
>
> Signed-off-by: Sanjana Sanikommu <sanjana99reddy99@gmail.com>
> ---
> drivers/staging/rtl8188eu/core/rtw_mlme.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/staging/rtl8188eu/core/rtw_mlme.c b/drivers/staging/rtl8188eu/core/rtw_mlme.c
> index ca0cf8a86671..cbee02a86d22 100644
> --- a/drivers/staging/rtl8188eu/core/rtw_mlme.c
> +++ b/drivers/staging/rtl8188eu/core/rtw_mlme.c
> @@ -1111,9 +1111,9 @@ static u8 search_max_mac_id(struct adapter *padapter)
> break;
> }
> mac_id = aid + 1;
> - } else
> + } else {
> #endif
> - {/* adhoc id = 31~2 */
> +/* adhoc id = 31~2 */
Never put anything in the first column within a function, unless it is a
jump label. This isn't ok, but most importantly, I think you broke the
build. The { is in that location for a reason, due to the #endif above
it, and can not be changed.
Please always think about the checkpatch changes you are making and do
not just blindly do them.
thanks,
greg k-h
next prev parent reply other threads:[~2019-03-18 13:55 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-18 12:59 [PATCH] Staging: rtl8188eu: core: rtw_mlme.c: Fix unbalanced braces around else Sanjana Sanikommu
2019-03-18 13:55 ` Greg KH [this message]
2019-03-18 14:18 ` sanjana99reddy99
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190318135521.GA7342@kroah.com \
--to=gregkh@linuxfoundation.org \
--cc=outreachy-kernel@googlegroups.com \
--cc=sanjana99reddy99@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.