From dfb47300472a7869319e2187adfee9d0759fa94a Mon Sep 17 00:00:00 2001 From: "Alfred E. Heggestad" Date: Fri, 29 Dec 2023 14:23:24 +0100 Subject: [PATCH] test: use re_is_aligned() --- include/re_types.h | 1 - test/mem.c | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/include/re_types.h b/include/re_types.h index 706c7fbad..739b1dcf0 100644 --- a/include/re_types.h +++ b/include/re_types.h @@ -53,7 +53,6 @@ typedef SSIZE_T ssize_t; /** Check alignment of pointer (p) and byte count (c) **/ #define re_is_aligned(p, c) (((uintptr_t)(const void *)(p)) % (c) == 0) -#define is_aligned re_is_aligned /** Get the minimal value */ #undef MIN diff --git a/test/mem.c b/test/mem.c index 71d7adda3..4b284e081 100644 --- a/test/mem.c +++ b/test/mem.c @@ -49,7 +49,7 @@ int test_mem(void) obj->pattern = PATTERN; TEST_EQUALS(1, mem_nrefs(obj)); - TEST_ASSERT(is_aligned(obj, mem_alignment)); + TEST_ASSERT(re_is_aligned(obj, mem_alignment)); obj = mem_ref(obj); TEST_EQUALS(2, mem_nrefs(obj)); @@ -67,7 +67,7 @@ int test_mem(void) TEST_ERR(err); } - TEST_ASSERT(is_aligned(obj, mem_alignment)); + TEST_ASSERT(re_is_aligned(obj, mem_alignment)); old = mem_ref(obj); TEST_EQUALS(2, mem_nrefs(obj));