commit 52c0d0588954aeebef5d9aba80ea51226dcfc240 parent e42881c4d1f70a6425981782216ab6212b415b42 Author: vx-clutch <[email protected]> Date: Thu, 13 Nov 2025 15:27:28 -0500 wip Diffstat:
| A | wrapper.c | | | 13 | +++++++++++++ |
| A | wrapper.h | | | 8 | ++++++++ |
2 files changed, 21 insertions(+), 0 deletions(-)
diff --git a/wrapper.c b/wrapper.c @@ -0,0 +1,13 @@ +#include <stdio.h> +#include <stdlib.h> + +#include "wrapper.h" +#include "usage.h" + +void *xmalloc(size_t size) +{ + void *ret = malloc(size); + if (!ret) + die("memory exhausted"); + return ret; +} diff --git a/wrapper.h b/wrapper.h @@ -0,0 +1,8 @@ +#ifndef WRAPPER_H_ +#define WRAPPER_H_ + +#include <stdio.h> + +void *xmalloc(size_t size); + +#endif