summaryrefslogtreecommitdiff
path: root/libmisc/assert.c
diff options
context:
space:
mode:
Diffstat (limited to 'libmisc/assert.c')
-rw-r--r--libmisc/assert.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/libmisc/assert.c b/libmisc/assert.c
index 8231c85..fdd8154 100644
--- a/libmisc/assert.c
+++ b/libmisc/assert.c
@@ -1,11 +1,10 @@
/* libmisc/assert.c - More assertions
*
- * Copyright (C) 2024 Luke T. Shumaker <lukeshu@lukeshu.com>
+ * Copyright (C) 2024-2025 Luke T. Shumaker <lukeshu@lukeshu.com>
* SPDX-License-Identifier: AGPL-3.0-or-later
*/
#include <stdbool.h> /* for bool, true, false */
-#include <stdlib.h> /* for abort() */
#define LOG_NAME ASSERT
#include <libmisc/log.h> /* for errorf() */
@@ -13,7 +12,7 @@
#include <libmisc/assert.h>
#ifndef NDEBUG
-[[noreturn, gnu::weak]]
+#define __lm_printf __lm_light_printf
void __assert_msg_fail(const char *expr,
const char *file, unsigned int line, const char *func,
const char *msg) {
@@ -26,6 +25,6 @@ void __assert_msg_fail(const char *expr,
msg ? ": " : "", msg ?: "");
in_fail = false;
}
- abort();
+ __lm_abort();
}
#endif