Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/tests/lib/libpthread Fix the t_join test
details: https://anonhg.NetBSD.org/src/rev/69bbb9cfeda5
branches: trunk
changeset: 744310:69bbb9cfeda5
user: kamil <kamil%NetBSD.org@localhost>
date: Wed Jan 29 13:40:23 2020 +0000
description:
Fix the t_join test
For pthread_attr_get_np() attr should be initialized prior to the call by
using pthread_attr_init(3). pthread_getattr_np() does this
automatically so switch to it.
diffstat:
tests/lib/libpthread/t_join.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (27 lines):
diff -r 17773b82acca -r 69bbb9cfeda5 tests/lib/libpthread/t_join.c
--- a/tests/lib/libpthread/t_join.c Wed Jan 29 12:05:08 2020 +0000
+++ b/tests/lib/libpthread/t_join.c Wed Jan 29 13:40:23 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: t_join.c,v 1.9 2017/07/02 16:41:33 joerg Exp $ */
+/* $NetBSD: t_join.c,v 1.10 2020/01/29 13:40:23 kamil Exp $ */
/*-
* Copyright (c) 2010 The NetBSD Foundation, Inc.
@@ -29,7 +29,7 @@
* POSSIBILITY OF SUCH DAMAGE.
*/
#include <sys/cdefs.h>
-__RCSID("$NetBSD: t_join.c,v 1.9 2017/07/02 16:41:33 joerg Exp $");
+__RCSID("$NetBSD: t_join.c,v 1.10 2020/01/29 13:40:23 kamil Exp $");
#include <errno.h>
#include <pthread.h>
@@ -153,7 +153,7 @@
j = (uintptr_t)arg;
- ATF_REQUIRE(pthread_attr_get_np(pthread_self(), &attr) == 0);
+ ATF_REQUIRE(pthread_getattr_np(pthread_self(), &attr) == 0);
ATF_REQUIRE(pthread_attr_getstacksize(&attr, &stacksize) == 0);
ATF_REQUIRE(stacksize == STACKSIZE * (j + 1));
ATF_REQUIRE(pthread_attr_getguardsize(&attr, &guardsize) == 0);
Home |
Main Index |
Thread Index |
Old Index