From 802c7807e5d0fd2406e24d9356fa285320e98a0a Mon Sep 17 00:00:00 2001 From: jsing Date: Tue, 11 Apr 2023 10:26:29 +0000 Subject: [PATCH] Omit sha512_block_data_order() prototype when assembly is not being used. In the case that the pure C implementation of SHA512 is being used, the prototype is unnecessary as the function is declared static and exists in dependency order. Simply omit the prototype rather than using #ifndef to toggle the static prefix. ok tb@ --- lib/libcrypto/sha/sha512.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/lib/libcrypto/sha/sha512.c b/lib/libcrypto/sha/sha512.c index d79e2879d2a..3fe20de51b3 100644 --- a/lib/libcrypto/sha/sha512.c +++ b/lib/libcrypto/sha/sha512.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sha512.c,v 1.25 2023/04/11 10:21:02 jsing Exp $ */ +/* $OpenBSD: sha512.c,v 1.26 2023/04/11 10:26:29 jsing Exp $ */ /* ==================================================================== * Copyright (c) 1998-2011 The OpenSSL Project. All rights reserved. * @@ -67,10 +67,9 @@ #define SHA512_BLOCK_CAN_MANAGE_UNALIGNED_DATA #endif -#ifndef SHA512_ASM -static +#ifdef SHA512_ASM +void sha512_block_data_order(SHA512_CTX *ctx, const void *in, size_t num); #endif -void sha512_block_data_order (SHA512_CTX *ctx, const void *in, size_t num); #ifndef SHA512_ASM static const SHA_LONG64 K512[80] = { -- 2.20.1