From: Bernd Edlinger Date: Sun, 26 Mar 2017 21:29:41 +0000 (+0200) Subject: Add parentheses around macro argument of OSSL_NELEM. X-Git-Tag: OpenSSL_1_1_1-pre1~1275 X-Git-Url: https://git.openssl.org/?p=openssl.git;a=commitdiff_plain;h=26dc47f3c44c7fb4488d1becaf997737486f4922 Add parentheses around macro argument of OSSL_NELEM. Reviewed-by: Richard Levitte Reviewed-by: Rich Salz (Merged from https://github.com/openssl/openssl/pull/3039) --- diff --git a/e_os.h b/e_os.h index 49a0c3ed18..d331044ead 100644 --- a/e_os.h +++ b/e_os.h @@ -539,7 +539,7 @@ struct servent *getservbyname(const char *name, const char *proto); # endif /* end vxworks */ -#define OSSL_NELEM(x) (sizeof(x)/sizeof(x[0])) +#define OSSL_NELEM(x) (sizeof(x)/sizeof((x)[0])) #ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION # define CRYPTO_memcmp memcmp