diff options
author | PikalaxALT <pikalaxalt@gmail.com> | 2018-02-11 20:12:40 -0500 |
---|---|---|
committer | PikalaxALT <pikalaxalt@gmail.com> | 2018-02-11 20:12:40 -0500 |
commit | 590c4b500b9dd37d372a935865aa4df0ab0bf43c (patch) | |
tree | 5572d76c91e106e74e1401076f130fb902f6b67b /include/malloc.h | |
parent | bc063b45d05716d1eab283f6d474bcdc601cafde (diff) | |
parent | 14a76793e596d612efd273169c4172922c270f13 (diff) |
Merge branch 'master' into record_mixing
Diffstat (limited to 'include/malloc.h')
-rw-r--r-- | include/malloc.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/malloc.h b/include/malloc.h index f3a731797..003ee1f03 100644 --- a/include/malloc.h +++ b/include/malloc.h @@ -5,6 +5,12 @@ #define calloc(ct, sz) AllocZeroed((ct) * (sz)) #define free Free +#define FREE_AND_SET_NULL(ptr) \ +{ \ + free(ptr); \ + ptr = NULL; \ +} + extern u8 gHeap[]; void *Alloc(u32 size); void *AllocZeroed(u32 size); |