Suppress -Warray-parameter warnings in pgcrypto/sha2.c.

This is exactly the same problem as commit 1b242f42b fixed in ecpg,
but in contrib/pgcrypto.  Commit 273c458a2 eliminated the problem
here for v10 and up.  We hadn't noticed for exactly the same reasons
enumerated in bbbf22cf3.

Back-patch down to 9.2, pursuant to newly-established project policy
about keeping out-of-support branches buildable.

Discussion: https://postgr.es/m/d0316012-ece7-7b7e-2d36-9c38cb77cb3b@enterprisedb.com
This commit is contained in:
Tom Lane 2021-12-12 20:24:38 -05:00
parent f420f24c0a
commit 116a509e09
1 changed files with 4 additions and 4 deletions

View File

@ -549,7 +549,7 @@ SHA256_Last(SHA256_CTX *context)
}
void
SHA256_Final(uint8 digest[], SHA256_CTX *context)
SHA256_Final(uint8 digest[SHA256_DIGEST_LENGTH], SHA256_CTX *context)
{
/* If no digest buffer is passed, we don't bother doing this: */
if (digest != NULL)
@ -877,7 +877,7 @@ SHA512_Last(SHA512_CTX *context)
}
void
SHA512_Final(uint8 digest[], SHA512_CTX *context)
SHA512_Final(uint8 digest[SHA512_DIGEST_LENGTH], SHA512_CTX *context)
{
/* If no digest buffer is passed, we don't bother doing this: */
if (digest != NULL)
@ -922,7 +922,7 @@ SHA384_Update(SHA384_CTX *context, const uint8 *data, size_t len)
}
void
SHA384_Final(uint8 digest[], SHA384_CTX *context)
SHA384_Final(uint8 digest[SHA384_DIGEST_LENGTH], SHA384_CTX *context)
{
/* If no digest buffer is passed, we don't bother doing this: */
if (digest != NULL)
@ -966,7 +966,7 @@ SHA224_Update(SHA224_CTX *context, const uint8 *data, size_t len)
}
void
SHA224_Final(uint8 digest[], SHA224_CTX *context)
SHA224_Final(uint8 digest[SHA224_DIGEST_LENGTH], SHA224_CTX *context)
{
/* If no digest buffer is passed, we don't bother doing this: */
if (digest != NULL)