wasi libc: remove malloc defines

This commit is contained in:
Andrew Kelley 2026-02-11 23:48:49 -08:00
parent e2fccd8dd5
commit f5d5dbd166
5 changed files with 0 additions and 26 deletions

View file

@ -4,11 +4,6 @@
#include "lock.h"
#include "fork_impl.h"
#define malloc __libc_malloc
#define calloc __libc_calloc
#define realloc undef
#define free undef
/* Ensure that at least 32 atexit handlers can be registered without malloc */
#define COUNT 32

View file

@ -10,10 +10,4 @@ hidden int __ptsname_r(int, char *, size_t);
hidden char *__randname(char *);
hidden void __qsort_r (void *, size_t, size_t, int (*)(const void *, const void *, void *), void *);
hidden void *__libc_malloc(size_t);
hidden void *__libc_malloc_impl(size_t);
hidden void *__libc_calloc(size_t, size_t);
hidden void *__libc_realloc(void *, size_t);
hidden void __libc_free(void *);
#endif

View file

@ -9,11 +9,6 @@
#include "lock.h"
#include "fork_impl.h"
#define malloc __libc_malloc
#define calloc undef
#define realloc undef
#define free undef
const char *__lctrans_impl(const char *msg, const struct __locale_map *lm)
{
const char *trans = 0;

View file

@ -6,11 +6,6 @@
#include "locale_impl.h"
#include "lock.h"
#define malloc __libc_malloc
#define calloc undef
#define realloc undef
#define free undef
static int default_locale_init_done;
static struct __locale_struct default_locale, default_ctype_locale;

View file

@ -11,11 +11,6 @@
#include "lock.h"
#include "fork_impl.h"
#define malloc __libc_malloc
#define calloc undef
#define realloc undef
#define free undef
#ifdef __wasilibc_unmodified_upstream // timezone data
long __timezone = 0;
int __daylight = 0;