summaryrefslogtreecommitdiff
path: root/libc/stdlib/malloc-simple
diff options
context:
space:
mode:
authorPeter S. Mazinger <ps.m@gmx.net>2011-03-21 15:01:50 +0100
committerBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2012-06-15 14:00:30 +0200
commit89b9f4592adb7aa2832b9efd95713b04f0ce185f (patch)
tree7baa2f082f21249eaa30605cd505c2ec8edf5259 /libc/stdlib/malloc-simple
parent3b879e2627693437365b0966d56223c4f00f8d60 (diff)
malloc-simple: make _aligned_blocks static and __libc_free_aligned hidden
move __libc_free_aligned prototype up to a common place. Signed-off-by: Peter S. Mazinger <ps.m@gmx.net> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Diffstat (limited to 'libc/stdlib/malloc-simple')
-rw-r--r--libc/stdlib/malloc-simple/alloc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libc/stdlib/malloc-simple/alloc.c b/libc/stdlib/malloc-simple/alloc.c
index 914c89dc0..11d4dcf23 100644
--- a/libc/stdlib/malloc-simple/alloc.c
+++ b/libc/stdlib/malloc-simple/alloc.c
@@ -17,6 +17,7 @@
#include <sys/mman.h>
#include <malloc.h>
+extern int weak_function __libc_free_aligned(void *ptr) attribute_hidden;
#ifdef L_malloc
void *malloc(size_t size)
@@ -95,7 +96,6 @@ void *realloc(void *ptr, size_t size)
#endif
#ifdef L_free
-extern int weak_function __libc_free_aligned(void *ptr);
void free(void *ptr)
{
if (unlikely(ptr == NULL))
@@ -123,7 +123,7 @@ struct alignlist
__ptr_t aligned; /* The address that memaligned returned. */
__ptr_t exact; /* The address that malloc returned. */
};
-struct alignlist *_aligned_blocks;
+static struct alignlist *_aligned_blocks;
/* Return memory to the heap. */
int __libc_free_aligned(void *ptr)