summaryrefslogtreecommitdiff
path: root/libc/stdlib/malloc
diff options
context:
space:
mode:
authorMiles Bader <miles@lsi.nec.co.jp>2002-08-19 08:45:22 +0000
committerMiles Bader <miles@lsi.nec.co.jp>2002-08-19 08:45:22 +0000
commitb348111d8ce0dd1849caf7e49fbbedf45f204c8b (patch)
tree8f4dc17d3d4a3e6f3593fb36ac521441ef6c5d2a /libc/stdlib/malloc
parentbdc62ea2b81f490d7ae398129085ccd088cef0d6 (diff)
(realloc): Follow new arg conventions of MALLOC_SET_SIZE.
Diffstat (limited to 'libc/stdlib/malloc')
-rw-r--r--libc/stdlib/malloc/realloc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libc/stdlib/malloc/realloc.c b/libc/stdlib/malloc/realloc.c
index 31639d7fe..db26866de 100644
--- a/libc/stdlib/malloc/realloc.c
+++ b/libc/stdlib/malloc/realloc.c
@@ -57,7 +57,7 @@ realloc (void *mem, size_t new_size)
if (extra)
/* Record the changed size. */
- MALLOC_SET_SIZE (mem, new_size);
+ MALLOC_SET_SIZE (base_mem, new_size);
else
/* Our attempts to extend MEM in place failed, just
allocate-and-copy. */
@@ -77,7 +77,7 @@ realloc (void *mem, size_t new_size)
__malloc_lock ();
__heap_free (&__malloc_heap, base_mem + new_size, size - new_size);
__malloc_unlock ();
- MALLOC_SET_SIZE (mem, new_size);
+ MALLOC_SET_SIZE (base_mem, new_size);
}
if (mem)