From 0ce905c057c3215d1fc1b1beb1900e206024afad Mon Sep 17 00:00:00 2001 From: Markus Uhlin Date: Wed, 3 Jan 2024 01:10:45 +0100 Subject: Added _assert_error() --- FICS/assert_error.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 FICS/assert_error.c (limited to 'FICS/assert_error.c') diff --git a/FICS/assert_error.c b/FICS/assert_error.c new file mode 100644 index 0000000..2d26491 --- /dev/null +++ b/FICS/assert_error.c @@ -0,0 +1,12 @@ +#include +#include + +#include "assert_error.h" + +__dead void +_assert_error(const char *file, const long int line) +{ + (void) fprintf(stderr, "Assertion failed: file %s, line %ld.\n", + file, line); + abort(); +} -- cgit v1.2.3