diff options
Diffstat (limited to 'crypto/ec/curve25519.c')
-rw-r--r-- | crypto/ec/curve25519.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/crypto/ec/curve25519.c b/crypto/ec/curve25519.c index 3f24215047..a291e6f472 100644 --- a/crypto/ec/curve25519.c +++ b/crypto/ec/curve25519.c @@ -19,6 +19,8 @@ #include <openssl/evp.h> #include <openssl/sha.h> +#include "internal/numbers.h" + #if defined(X25519_ASM) && (defined(__x86_64) || defined(__x86_64__) || \ defined(_M_AMD64) || defined(_M_X64)) @@ -260,7 +262,7 @@ static void x25519_scalar_mulx(uint8_t out[32], const uint8_t scalar[32], #endif #if defined(X25519_ASM) \ - || ( (defined(__SIZEOF_INT128__) && __SIZEOF_INT128__ == 16) \ + || ( defined(INT128_MAX) \ && !defined(__sparc__) \ && (!defined(__SIZEOF_LONG__) || (__SIZEOF_LONG__ == 8)) \ && !(defined(__ANDROID__) && !defined(__clang__)) ) @@ -393,7 +395,7 @@ void x25519_fe51_mul121666(fe51 h, fe51 f); # define fe51_mul121666 x25519_fe51_mul121666 # else -typedef __uint128_t u128; +typedef uint128_t u128; static void fe51_mul(fe51 h, const fe51 f, const fe51 g) { |