From: Bhaktipriya Shridhar <bhaktipriya96@gmail.com>
To: outreachy-kernel@googlegroups.com
Subject: [PATCH] staging: rtl8712: xmit_linux: Remove unnecessary else after return
Date: Thu, 10 Mar 2016 22:17:12 +0530 [thread overview]
Message-ID: <20160310164711.GA18407@Karyakshetra> (raw)
This patch fixes the checkpatch warning that else is not generally
useful after a break or return.
This was done using Coccinelle:
@@
expression e2;
statement s1;
@@
if(e2) { ... return ...; }
-else
s1
Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com>
---
drivers/staging/rtl8712/xmit_linux.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/staging/rtl8712/xmit_linux.c b/drivers/staging/rtl8712/xmit_linux.c
index f8866d7..adb51f0 100644
--- a/drivers/staging/rtl8712/xmit_linux.c
+++ b/drivers/staging/rtl8712/xmit_linux.c
@@ -72,8 +72,7 @@ sint r8712_endofpktfile(struct pkt_file *pfile)
{
if (pfile->pkt_len == 0)
return true;
- else
- return false;
+ return false;
}
--
2.1.4
next reply other threads:[~2016-03-10 16:59 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-10 16:47 Bhaktipriya Shridhar [this message]
2016-03-11 18:32 ` [Outreachy kernel] [PATCH] staging: rtl8712: xmit_linux: Remove unnecessary else after return Greg KH
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=20160310164711.GA18407@Karyakshetra \
--to=bhaktipriya96@gmail.com \
--cc=outreachy-kernel@googlegroups.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.