]> git.ipfire.org Git - ipfire-2.x.git/blame - src/patches/glibc/glibc-rh1256812-2.patch
dhcpcd: fix delay after dhcp down.
[ipfire-2.x.git] / src / patches / glibc / glibc-rh1256812-2.patch
CommitLineData
bb330e25
AF
1diff -pruN glibc-2.12-2-gc4ccff1/malloc/malloc.c glibc-2.12-2-gc4ccff1.new/malloc/malloc.c
2--- glibc-2.12-2-gc4ccff1/malloc/malloc.c 2015-07-28 22:28:22.517107147 +0530
3+++ glibc-2.12-2-gc4ccff1.new/malloc/malloc.c 2015-07-28 22:24:59.541394493 +0530
4@@ -4087,8 +4087,9 @@ public_cALLOc(size_t n, size_t elem_size
5 /* Maybe the failure is due to running out of mmapped areas. */
6 if(av != &main_arena) {
7 (void)mutex_unlock(&av->mutex);
8- (void)mutex_lock(&main_arena.mutex);
9- mem = _int_malloc(&main_arena, sz);
10+ av = &main_arena;
11+ (void)mutex_lock(&av->mutex);
12+ mem = _int_malloc(av, sz);
13 } else {
14 #if USE_ARENAS
15 /* ... or sbrk() has failed and there is still a chance to mmap() */