diff mbox series

crypto: keywrap: Remove else after break statement

Message ID 20210326181359.97406-1-mdjurovic@zohomail.com (mailing list archive)
State Accepted
Delegated to: Herbert Xu
Headers show
Series crypto: keywrap: Remove else after break statement | expand

Commit Message

Milan Djurovic March 26, 2021, 6:13 p.m. UTC
Remove the else because the if statement has a break statement. Fix the
checkpatch.pl warning.

Signed-off-by: Milan Djurovic <mdjurovic@zohomail.com>
---
 crypto/keywrap.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Herbert Xu April 2, 2021, 9:48 a.m. UTC | #1
On Fri, Mar 26, 2021 at 11:13:59AM -0700, Milan Djurovic wrote:
> Remove the else because the if statement has a break statement. Fix the
> checkpatch.pl warning.
> 
> Signed-off-by: Milan Djurovic <mdjurovic@zohomail.com>
> ---
>  crypto/keywrap.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)

Patch applied.  Thanks.
diff mbox series

Patch

diff --git a/crypto/keywrap.c b/crypto/keywrap.c
index 3517773bc7f7..054d9a216fc9 100644
--- a/crypto/keywrap.c
+++ b/crypto/keywrap.c
@@ -114,9 +114,9 @@  static void crypto_kw_scatterlist_ff(struct scatter_walk *walk,
 			scatterwalk_start(walk, sg);
 			scatterwalk_advance(walk, skip);
 			break;
-		} else
-			skip -= sg->length;
+		}
 
+		skip -= sg->length;
 		sg = sg_next(sg);
 	}
 }