From 2e90022d5ce70aa4d2ed0c5889d5743643ec52cf Mon Sep 17 00:00:00 2001 From: Bill Currie Date: Fri, 22 Sep 2023 20:22:24 +0900 Subject: [PATCH] [util] Define ALLOC_STATE for DEBUG_QF_MEMORY I haven't used DEBUG_QF_MEMORY for a while, so it suffered a bit of bitrot. --- include/QF/alloc.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/QF/alloc.h b/include/QF/alloc.h index a22ad78eb..fd6337901 100644 --- a/include/QF/alloc.h +++ b/include/QF/alloc.h @@ -106,6 +106,9 @@ static struct DARRAY_TYPE(t *) n##_blocks = DARRAY_STATIC_INIT(8) v = (t *) calloc (1, sizeof (t)); \ } while (0) +#define ALLOC_STATE(t,n) \ +static t *n##_freelist; + #define FREE(n, p) do { free (p); } while (0) #endif