[lsan] give a test a bit more stack -- it started failing after r279664 on the debian bot, hopefully this is a fix.

llvm-svn: 279674
This commit is contained in:
Kostya Serebryany 2016-08-24 22:10:35 +00:00
parent 7f5884a489
commit db0fcdb03b
1 changed files with 3 additions and 2 deletions

View File

@ -22,6 +22,7 @@ static void die(const char* msg, int err) {
static void ctxfunc() {
pthread_mutex_lock(&mutex);
ctxfunc_started = 1;
printf("ctxfunc\n");
pthread_cond_signal(&cond);
pthread_mutex_unlock(&mutex);
// Leave this context alive when the program exits.
@ -35,11 +36,11 @@ static void* thread(void* arg) {
if (getcontext(&ctx) < 0)
die("getcontext", 0);
stack = malloc(1 << 10);
stack = malloc(1 << 12);
if (stack == NULL)
die("malloc", 0);
ctx.uc_stack.ss_sp = stack;
ctx.uc_stack.ss_size = 1 << 10;
ctx.uc_stack.ss_size = 1 << 12;
makecontext(&ctx, ctxfunc, 0);
setcontext(&ctx);
die("setcontext", 0);