All of lore.kernel.org
 help / color / mirror / Atom feed
From: Amitoj Kaur Chawla <amitoj1606@gmail.com>
To: outreachy-kernel@googlegroups.com
Subject: [PATCH v2 2/3] staging: lustre: libcfs: Remove unnecessary braces
Date: Tue, 23 Feb 2016 19:52:15 +0530	[thread overview]
Message-ID: <5f663d76fed48e495ffdfddf2038546e86642657.1456236436.git.amitoj1606@gmail.com> (raw)
In-Reply-To: <cover.1456236436.git.amitoj1606@gmail.com>

Removed unncessary braces from the if-else block to remove the
following checkpatch.pl warning:
WARNING: braces {} are not necessary for any arm of this statement

Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com>
---
Changes in v2:
        -Divide one patch into a series.

 drivers/staging/lustre/lustre/libcfs/hash.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/staging/lustre/lustre/libcfs/hash.c b/drivers/staging/lustre/lustre/libcfs/hash.c
index c8d8bc8..b9bdb67 100644
--- a/drivers/staging/lustre/lustre/libcfs/hash.c
+++ b/drivers/staging/lustre/lustre/libcfs/hash.c
@@ -800,12 +800,10 @@ cfs_hash_bd_order(struct cfs_hash_bd *bd1, struct cfs_hash_bd *bd2)
 	}
 
 	rc = cfs_hash_bd_compare(bd1, bd2);
-	if (rc == 0) {
+	if (rc == 0)
 		bd2->bd_bucket = NULL;
-
-	} else if (rc > 0) {
+	else if (rc > 0)
 		swap(*bd1, *bd2); /* swab bd1 and bd2 */
-	}
 }
 
 void
-- 
1.9.1



  parent reply	other threads:[~2016-02-23 14:22 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <cover.1456236436.git.amitoj1606@gmail.com>
2016-02-23 14:22 ` [PATCH v2 1/3] staging: lustre: libcfs: Use swap() in cfs_hash_bd_order() Amitoj Kaur Chawla
2016-02-23 19:25   ` [Outreachy kernel] " Julia Lawall
2016-02-23 19:27     ` Amitoj Kaur Chawla
2016-02-23 14:22 ` Amitoj Kaur Chawla [this message]
2016-02-23 14:22 ` [PATCH v2 3/3] staging: lustre: libcfs: Remove comparison with zero Amitoj Kaur Chawla

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=5f663d76fed48e495ffdfddf2038546e86642657.1456236436.git.amitoj1606@gmail.com \
    --to=amitoj1606@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.