From eab708047a937230584142a2714d5293b2c20176 Mon Sep 17 00:00:00 2001 From: jsing <> Date: Tue, 10 Jun 2014 14:14:07 +0000 Subject: Use C99 initialisers for EVP_MD structs, for clarity, grepability and to protect from future field reordering/removal. No difference in generated assembly. --- src/lib/libcrypto/evp/m_null.c | 28 ++++++++++++++++------------ 1 file changed, 16 insertions(+), 12 deletions(-) (limited to 'src/lib/libcrypto/evp/m_null.c') diff --git a/src/lib/libcrypto/evp/m_null.c b/src/lib/libcrypto/evp/m_null.c index ad658e7045..ecd0c2f2d6 100644 --- a/src/lib/libcrypto/evp/m_null.c +++ b/src/lib/libcrypto/evp/m_null.c @@ -81,18 +81,22 @@ final(EVP_MD_CTX *ctx, unsigned char *md) } static const EVP_MD null_md = { - NID_undef, - NID_undef, - 0, - 0, - init, - update, - final, - NULL, - NULL, - EVP_PKEY_NULL_method, - 0, - sizeof(EVP_MD *), + .type = NID_undef, + .pkey_type = NID_undef, + .md_size = 0, + .flags = 0, + .init = init, + .update = update, + .final = final, + .copy = NULL, + .cleanup = NULL, + .sign = NULL, + .verify = NULL, + .required_pkey_type = { + 0, 0, 0, 0, + }, + .block_size = 0, + .ctx_size = sizeof(EVP_MD *), }; const EVP_MD * -- cgit v1.2.3-55-g6feb