aboutsummaryrefslogtreecommitdiff
path: root/malloc
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2002-03-13 23:27:20 +0000
committerUlrich Drepper <drepper@redhat.com>2002-03-13 23:27:20 +0000
commit75bfdfc7df6d3557358fe7f1c01e748ef6b5efc7 (patch)
tree23e021859a45a505834a176c20d2d6fede2cd3fe /malloc
parentbf494c7d6b9e45aa5f7bd7667423a3b13dba0da6 (diff)
downloadglibc-75bfdfc7df6d3557358fe7f1c01e748ef6b5efc7.tar
glibc-75bfdfc7df6d3557358fe7f1c01e748ef6b5efc7.tar.gz
glibc-75bfdfc7df6d3557358fe7f1c01e748ef6b5efc7.tar.bz2
glibc-75bfdfc7df6d3557358fe7f1c01e748ef6b5efc7.zip
Update.
2002-03-13 Wolfram Gloger <wg@malloc.de> * malloc/malloc.c (sYSMALLOc): Don't change brk if mmap failed. 2002-03-02 Andreas Schwab <schwab@suse.de> * stdio-common/vfprintf.c (process_arg): Fix decimal format with 'h' flag and positional arg. * stdio-common/tst-printf.c (rfg3): New function to test positional arguments. (main): Fix some warnings. 2002-03-13 Jakub Jelinek <jakub@redhat.com> * elf/dl-minimal.c (_itoa): Use _itoa_lower_digits_internal if SHARED. * elf/dl-reloc.c (_dl_reloc_bad_type): Likewise.
Diffstat (limited to 'malloc')
-rw-r--r--malloc/malloc.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/malloc/malloc.c b/malloc/malloc.c
index 7414c705a9..059508a95e 100644
--- a/malloc/malloc.c
+++ b/malloc/malloc.c
@@ -2824,11 +2824,12 @@ static Void_t* sYSMALLOc(nb, av) INTERNAL_SIZE_T nb; mstate av;
/* Don't try if size wraps around 0 */
if ((unsigned long)(size) > (unsigned long)(nb)) {
- brk = (char*)(MMAP(0, size, PROT_READ|PROT_WRITE, MAP_PRIVATE));
+ char *mbrk = (char*)(MMAP(0, size, PROT_READ|PROT_WRITE, MAP_PRIVATE));
- if (brk != MAP_FAILED) {
+ if (mbrk != MAP_FAILED) {
/* We do not need, and cannot use, another sbrk call to find end */
+ brk = mbrk;
snd_brk = brk + size;
/*