Merge pull request #7960 from daverodgman/expect-fix

This commit is contained in:
Dave Rodgman 2023-07-19 19:48:15 +01:00 committed by GitHub
commit 7fa27a1a18
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -295,8 +295,8 @@ static inline void mbedtls_xor_no_simd(unsigned char *r,
/* Define compiler branch hints */
#if defined(__has_builtin)
#if __has_builtin(__builtin_expect)
#define MBEDTLS_LIKELY(x) __builtin_expect((x), 1)
#define MBEDTLS_UNLIKELY(x) __builtin_expect((x), 0)
#define MBEDTLS_LIKELY(x) __builtin_expect(!!(x), 1)
#define MBEDTLS_UNLIKELY(x) __builtin_expect(!!(x), 0)
#endif
#endif
#if !defined(MBEDTLS_LIKELY)