From bbd92009fc77b65f9fe3875725734dc72afc70cd Mon Sep 17 00:00:00 2001 From: Jakub Jelen Date: Tue, 27 Feb 2018 15:40:22 +0100 Subject: [PATCH] libcheck 0.9 compatibility for RHEL7 --- lib/tests/api.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/tests/api.c b/lib/tests/api.c index bd2437d..a41e08c 100644 --- a/lib/tests/api.c +++ b/lib/tests/api.c @@ -52,6 +52,10 @@ int destruction_confirmed(void); #ifndef ck_assert_mem_eq #define ck_assert_mem_eq(a,b,n) ck_assert(memcmp((a), (b), (n)) == 0) #endif +// only defined in libcheck 0.10+ (RHEL7 is still shipping 0.9) +#ifndef ck_assert_ptr_eq +#define ck_assert_ptr_eq(a,b) ck_assert((void *)(a) == (void *)(b)) +#endif ykpiv_state *g_state; const uint8_t g_cert[] = {