From e31ba8b9a7549dd0684c271115943854ac43c0ab Mon Sep 17 00:00:00 2001 From: dfr Date: Mon, 23 Aug 2004 15:30:05 +0000 Subject: Make sure we allocate at least enough space for the TCB for variant I TLS. MFC after: 3 days --- lib/libc/gen/tls.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'lib/libc') diff --git a/lib/libc/gen/tls.c b/lib/libc/gen/tls.c index 7a3ebfe..6948912 100644 --- a/lib/libc/gen/tls.c +++ b/lib/libc/gen/tls.c @@ -109,6 +109,8 @@ _rtld_allocate_tls(void *oldtls, size_t tcbsize, size_t tcbalign) Elf_Addr *dtv; size = tls_static_space; + if (size < tcbsize) + size = tcbsize; tls = malloc(size); dtv = malloc(3 * sizeof(Elf_Addr)); -- cgit v1.1