* [PATCH] crypto: ccm - remove goto
@ 2015-10-13 8:18 Sudip Mukherjee
2015-10-14 14:13 ` Herbert Xu
0 siblings, 1 reply; 2+ messages in thread
From: Sudip Mukherjee @ 2015-10-13 8:18 UTC (permalink / raw)
To: Herbert Xu, David S. Miller; +Cc: linux-kernel, linux-crypto, Sudip Mukherjee
Instead of using goto and jumping to a label and then returning from
there, lets return directly. The label out: is not used from anywhere
else in the code.
Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
---
crypto/ccm.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/crypto/ccm.c b/crypto/ccm.c
index cc31ea4..daa7e6d 100644
--- a/crypto/ccm.c
+++ b/crypto/ccm.c
@@ -881,14 +881,13 @@ static int crypto_rfc4309_create(struct crypto_template *tmpl,
if (err)
goto out_drop_alg;
-out:
return err;
out_drop_alg:
crypto_drop_aead(spawn);
out_free_inst:
kfree(inst);
- goto out;
+ return err;
}
static struct crypto_template crypto_rfc4309_tmpl = {
--
1.9.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] crypto: ccm - remove goto
2015-10-13 8:18 [PATCH] crypto: ccm - remove goto Sudip Mukherjee
@ 2015-10-14 14:13 ` Herbert Xu
0 siblings, 0 replies; 2+ messages in thread
From: Herbert Xu @ 2015-10-14 14:13 UTC (permalink / raw)
To: Sudip Mukherjee; +Cc: David S. Miller, linux-kernel, linux-crypto
On Tue, Oct 13, 2015 at 01:48:25PM +0530, Sudip Mukherjee wrote:
> Instead of using goto and jumping to a label and then returning from
> there, lets return directly. The label out: is not used from anywhere
> else in the code.
>
> Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
I don't think patch improves the code so I'm not taking it.
Cheers,
--
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-10-14 14:13 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-10-13 8:18 [PATCH] crypto: ccm - remove goto Sudip Mukherjee
2015-10-14 14:13 ` Herbert Xu
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).