1
0
Fork 0

Add realloc to export

This commit is contained in:
Pabloader 2025-05-08 19:10:47 +00:00
parent af8df2bd6f
commit bde4ecdb3b
1 changed files with 2 additions and 1 deletions

View File

@ -1,6 +1,6 @@
#pragma once
#include <stdint.h>
#include <stdbool.h>
#include <stdint.h>
extern unsigned char __heap_base;
#define IMPORT(name) __attribute__((import_module("env"), import_name(#name)))
@ -12,6 +12,7 @@ typedef uint32_t size_t;
EXPORT(malloc) void* malloc(size_t);
EXPORT(free) void free(void*);
EXPORT(realloc) void* realloc(void*, size_t);
void* memset(void* s, uint8_t c, uint32_t n);
void* memcpy(void* dest, const void* src, uint32_t n);