umalloc fixes

This commit is contained in:
2025-09-28 19:55:37 +02:00
parent c07a2c957b
commit 96ce9233ff
6 changed files with 105 additions and 70 deletions

View File

@ -1,13 +1,13 @@
#ifndef ULIB_ASSERT_H_
#define ULIB_ASSERT_H_
#include <uprintf.h>
#include <write/write.h>
#include <util/util.h>
#define ASSERT(X, fmt, ...) \
do { \
if (!(X)) { \
uprintf("ASSERT %s:%d in %s "fmt, __FILE__, __LINE__, __func__, ##__VA_ARGS__); \
writefmt("ASSERT {s}:{d} in {s} "fmt, __FILE__, __LINE__, __func__, ##__VA_ARGS__); \
quit(); \
} \
} while(0)