summaryrefslogtreecommitdiff
path: root/sys/crypto
diff options
context:
space:
mode:
authorMike Belopuhov <mikeb@cvs.openbsd.org>2015-11-18 12:23:15 +0000
committerMike Belopuhov <mikeb@cvs.openbsd.org>2015-11-18 12:23:15 +0000
commitb546534660a436e1ae9f9adc10b36c12284ad808 (patch)
treeb4740cc620b65f65a5e10a912ad13f85b8581d14 /sys/crypto
parent6a0d3a8ad4e103ec7039e2c04649ab4c7072f500 (diff)
Cleanup gotos as suggested by jsing@ along with spaces and label names
Diffstat (limited to 'sys/crypto')
-rw-r--r--sys/crypto/cryptosoft.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/sys/crypto/cryptosoft.c b/sys/crypto/cryptosoft.c
index c5aa57f7992..3c7d72dfb45 100644
--- a/sys/crypto/cryptosoft.c
+++ b/sys/crypto/cryptosoft.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cryptosoft.c,v 1.78 2015/11/13 12:21:16 mikeb Exp $ */
+/* $OpenBSD: cryptosoft.c,v 1.79 2015/11/18 12:23:14 mikeb Exp $ */
/*
* The author of this code is Angelos D. Keromytis (angelos@cis.upenn.edu)
@@ -857,6 +857,7 @@ swcr_newsession(u_int32_t *sid, struct cryptoini *cri)
goto authcommon;
case CRYPTO_SHA2_512_HMAC:
axf = &auth_hash_hmac_sha2_512_256;
+ goto authcommon;
authcommon:
(*swd)->sw_ictx = malloc(axf->ctxsize, M_CRYPTO_DATA,
M_NOWAIT);
@@ -897,19 +898,17 @@ swcr_newsession(u_int32_t *sid, struct cryptoini *cri)
case CRYPTO_AES_128_GMAC:
axf = &auth_hash_gmac_aes_128;
- goto auth4common;
-
+ goto authenccommon;
case CRYPTO_AES_192_GMAC:
axf = &auth_hash_gmac_aes_192;
- goto auth4common;
-
+ goto authenccommon;
case CRYPTO_AES_256_GMAC:
axf = &auth_hash_gmac_aes_256;
- goto auth4common;
-
+ goto authenccommon;
case CRYPTO_CHACHA20_POLY1305_MAC:
axf = &auth_hash_chacha20_poly1305;
- auth4common:
+ goto authenccommon;
+ authenccommon:
(*swd)->sw_ictx = malloc(axf->ctxsize, M_CRYPTO_DATA,
M_NOWAIT);
if ((*swd)->sw_ictx == NULL) {