aboutsummaryrefslogtreecommitdiff
path: root/sys/libn/memory.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/libn/memory.c')
-rw-r--r--sys/libn/memory.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/sys/libn/memory.c b/sys/libn/memory.c
index dce0c36..7993ca2 100644
--- a/sys/libn/memory.c
+++ b/sys/libn/memory.c
@@ -1,6 +1,26 @@
#include <u.h>
#include <libn.h>
+void
+·free(void* _, void* ptr) {
+ return free(ptr);
+}
+
+void *
+·alloc(void* _, uint n, ulong size) {
+ return malloc(n*size);
+}
+
+void *
+·calloc(void* _, uint n, ulong size) {
+ return calloc(n, size);
+}
+
+void *
+·realloc(void* _, void *ptr, uint n, ulong size) {
+ return realloc(ptr, n*size);
+}
+
// -------------------------------------------------------------------------
// Dynamic buffer.