summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorjsing <>2023-05-28 13:55:55 +0000
committerjsing <>2023-05-28 13:55:55 +0000
commit3c370dcc242f677576f3aa514b79ba102f5cee7f (patch)
treed5ff37231b770472f24cae4a594c0751a3e8bc68 /src/lib
parent525264cba68648274a8a172fb85bb140cf4c001d (diff)
downloadopenbsd-3c370dcc242f677576f3aa514b79ba102f5cee7f.tar.gz
openbsd-3c370dcc242f677576f3aa514b79ba102f5cee7f.tar.bz2
openbsd-3c370dcc242f677576f3aa514b79ba102f5cee7f.zip
Remove now unnecessary do {} while(0);
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/libcrypto/sha/sha256.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/lib/libcrypto/sha/sha256.c b/src/lib/libcrypto/sha/sha256.c
index 689ee89454..8ee23f3474 100644
--- a/src/lib/libcrypto/sha/sha256.c
+++ b/src/lib/libcrypto/sha/sha256.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: sha256.c,v 1.17 2023/05/28 13:53:08 jsing Exp $ */ 1/* $OpenBSD: sha256.c,v 1.18 2023/05/28 13:55:55 jsing Exp $ */
2/* ==================================================================== 2/* ====================================================================
3 * Copyright (c) 1998-2011 The OpenSSL Project. All rights reserved. 3 * Copyright (c) 1998-2011 The OpenSSL Project. All rights reserved.
4 * 4 *
@@ -267,7 +267,6 @@ SHA256_Final(unsigned char *md, HASH_CTX *c)
267 * Idea behind separate cases for pre-defined lengths is to let the 267 * Idea behind separate cases for pre-defined lengths is to let the
268 * compiler decide if it's appropriate to unroll small loops. 268 * compiler decide if it's appropriate to unroll small loops.
269 */ 269 */
270 do {
271 switch (c->md_len) { 270 switch (c->md_len) {
272 case SHA224_DIGEST_LENGTH: 271 case SHA224_DIGEST_LENGTH:
273 for (nn = 0; nn < SHA224_DIGEST_LENGTH / 4; nn++) { 272 for (nn = 0; nn < SHA224_DIGEST_LENGTH / 4; nn++) {
@@ -292,7 +291,6 @@ SHA256_Final(unsigned char *md, HASH_CTX *c)
292 } 291 }
293 break; 292 break;
294 } 293 }
295 } while (0);
296 294
297 return 1; 295 return 1;
298} 296}