diff options
Diffstat (limited to 'nptl/tst-join4.c')
-rw-r--r-- | nptl/tst-join4.c | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/nptl/tst-join4.c b/nptl/tst-join4.c index 0b605907da..b13a510111 100644 --- a/nptl/tst-join4.c +++ b/nptl/tst-join4.c @@ -1,4 +1,4 @@ -/* Copyright (C) 2003 Free Software Foundation, Inc. +/* Copyright (C) 2003, 2004 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Ulrich Drepper <drepper@redhat.com>, 2003. @@ -48,19 +48,25 @@ do_test (void) exit (1); } - pthread_t th[2]; + pthread_attr_t a; - if (pthread_create (&th[0], NULL, tf, NULL) != 0) + if (pthread_attr_init (&a) != 0) { - puts ("1st create failed"); + puts ("attr_init failed"); exit (1); } - pthread_attr_t a; + if (pthread_attr_setstacksize (&a, 1 * 1024 * 1024) != 0) + { + puts ("attr_setstacksize failed"); + return 1; + } - if (pthread_attr_init (&a) != 0) + pthread_t th[2]; + + if (pthread_create (&th[0], &a, tf, NULL) != 0) { - puts ("attr_init failed"); + puts ("1st create failed"); exit (1); } |