diff -r db06dda7ac4d -r a10c3e127050 src/allocator.c --- a/src/allocator.c Sun Oct 03 12:04:27 2021 +0200 +++ b/src/allocator.c Sun Oct 03 13:07:48 2021 +0200 @@ -30,17 +30,17 @@ #include -__attribute__((__malloc__)) +__attribute__((__malloc__, __alloc_size__(2))) static void *cx_malloc_stdlib(__attribute__((__unused__)) void *d, size_t n) { return malloc(n); } -__attribute__((__warn_unused_result__)) +__attribute__((__warn_unused_result__, __alloc_size__(3))) static void *cx_realloc_stdlib(__attribute__((__unused__)) void *d, void *mem, size_t n) { return realloc(mem, n); } -__attribute__((__malloc__)) +__attribute__((__malloc__, __alloc_size__(2, 3))) static void *cx_calloc_stdlib(__attribute__((__unused__)) void *d, size_t nelem, size_t n) { return calloc(nelem, n); }