From 013f366f501c928315cc2893f0f2348c8956d09e Mon Sep 17 00:00:00 2001 From: Waldemar Brodkorb Date: Tue, 20 Dec 2016 20:51:59 +0100 Subject: remove __MALLOC_GLIBC_COMPAT__ option This option is enabled for a long time and I see no useful case where we should be incompatible to glibc here. --- libc/stdlib/malloc-simple/alloc.c | 6 ------ 1 file changed, 6 deletions(-) (limited to 'libc/stdlib/malloc-simple/alloc.c') diff --git a/libc/stdlib/malloc-simple/alloc.c b/libc/stdlib/malloc-simple/alloc.c index a3c068a5b..3baf75fdd 100644 --- a/libc/stdlib/malloc-simple/alloc.c +++ b/libc/stdlib/malloc-simple/alloc.c @@ -25,13 +25,7 @@ void *malloc(size_t size) void *result; if (unlikely(size == 0)) { -#if defined(__MALLOC_GLIBC_COMPAT__) size++; -#else - /* Some programs will call malloc (0). Lets be strict and return NULL */ - __set_errno(ENOMEM); - return NULL; -#endif } #ifdef __ARCH_USE_MMU__ -- cgit v1.2.3