aboutsummaryrefslogtreecommitdiff
path: root/malloc/malloc.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2010-03-26 04:00:10 -0700
committerUlrich Drepper <drepper@redhat.com>2010-03-26 04:00:10 -0700
commit3e259dbb32c2456e7fc0fc751b8544fd0939a704 (patch)
treea67d4ba4ac1b1a78abcd28fbaf364c90149b6736 /malloc/malloc.c
parent70c90289ff7e2f1ca976618bcf342d9c65c746fc (diff)
downloadglibc-3e259dbb32c2456e7fc0fc751b8544fd0939a704.tar
glibc-3e259dbb32c2456e7fc0fc751b8544fd0939a704.tar.gz
glibc-3e259dbb32c2456e7fc0fc751b8544fd0939a704.tar.bz2
glibc-3e259dbb32c2456e7fc0fc751b8544fd0939a704.zip
Remove unwanted malloc changes, again.
Diffstat (limited to 'malloc/malloc.c')
-rw-r--r--malloc/malloc.c15
1 files changed, 1 insertions, 14 deletions
diff --git a/malloc/malloc.c b/malloc/malloc.c
index 0004c878f3..763852ea3b 100644
--- a/malloc/malloc.c
+++ b/malloc/malloc.c
@@ -4852,8 +4852,7 @@ _int_free(mstate av, mchunkptr p)
free_perturb (chunk2mem(p), size - SIZE_SZ);
set_fastchunks(av);
- unsigned int idx = fastbin_index(size);
- fb = &fastbin (av, idx);
+ fb = &fastbin (av, fastbin_index(size));
#ifdef ATOMIC_FASTBINS
mchunkptr fd;
@@ -4867,12 +4866,6 @@ _int_free(mstate av, mchunkptr p)
errstr = "double free or corruption (fasttop)";
goto errout;
}
- if (old != NULL
- && __builtin_expect (fastbin_index(chunksize(old)) != idx, 0))
- {
- errstr = "invalid fastbin entry (free)";
- goto errout;
- }
p->fd = fd = old;
}
while ((old = catomic_compare_and_exchange_val_rel (fb, p, fd)) != fd);
@@ -4884,12 +4877,6 @@ _int_free(mstate av, mchunkptr p)
errstr = "double free or corruption (fasttop)";
goto errout;
}
- if (*fb != NULL
- && __builtin_expect (fastbin_index(chunksize(*fb)) != idx, 0))
- {
- errstr = "invalid fastbin entry (free)";
- goto errout;
- }
p->fd = *fb;
*fb = p;