From 79284b25994d90149f4a9a5286ec739770db94ea Mon Sep 17 00:00:00 2001 From: "Luke T. Shumaker" Date: Tue, 17 Dec 2024 19:18:21 -0700 Subject: libmisc: Rework how test-intercepts work --- libmisc/tests/test_rand.c | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) (limited to 'libmisc/tests/test_rand.c') diff --git a/libmisc/tests/test_rand.c b/libmisc/tests/test_rand.c index fff1b27..295ea61 100644 --- a/libmisc/tests/test_rand.c +++ b/libmisc/tests/test_rand.c @@ -8,6 +8,7 @@ #include #include +#include #include "test.h" @@ -15,19 +16,9 @@ jmp_buf *__catch; -void __assert_msg_fail(const char *expr, - const char *file, unsigned int line, const char *func, - const char *msg) { - static bool in_fail = false; +void __lm_abort(void) { if (__catch) longjmp(*__catch, 1); - if (!in_fail) { - in_fail = true; - printf("error: %s:%u:%s(): assertion \"%s\" failed%s%s\n", - file, line, func, - expr, - msg ? ": " : "", msg); - } abort(); } -- cgit v1.2.3-2-g168b