Backport OSSL_NELEM
authorRich Salz <rsalz@openssl.org>
Wed, 22 Feb 2017 20:38:09 +0000 (15:38 -0500)
committerRich Salz <rsalz@openssl.org>
Thu, 23 Feb 2017 14:12:07 +0000 (09:12 -0500)
Reviewed-by: Tim Hudson <tjh@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/2713)

crypto/ec/ec_asn1.c

index cf81841035473d7f626c03496f81519040be14b9..b0cd3e1788dcae7d944883ea21f6932b68b12563 100644 (file)
@@ -62,6 +62,8 @@
 #include <openssl/asn1t.h>
 #include <openssl/objects.h>
 
+#define OSSL_NELEM(x)    (sizeof(x)/sizeof(x[0]))
+
 int EC_GROUP_get_basis_type(const EC_GROUP *group)
 {
     int i;