Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/tests/lib/libpthread PR/51884: Ngie Cooper: Include and mess...
details: https://anonhg.NetBSD.org/src/rev/6e6d6871bf02
branches: trunk
changeset: 350696:6e6d6871bf02
user: christos <christos%NetBSD.org@localhost>
date: Mon Jan 16 16:29:19 2017 +0000
description:
PR/51884: Ngie Cooper: Include and message fixes
diffstat:
tests/lib/libpthread/t_condwait.c | 11 +++++++----
1 files changed, 7 insertions(+), 4 deletions(-)
diffs (40 lines):
diff -r 85a547e0b17c -r 6e6d6871bf02 tests/lib/libpthread/t_condwait.c
--- a/tests/lib/libpthread/t_condwait.c Mon Jan 16 16:28:27 2017 +0000
+++ b/tests/lib/libpthread/t_condwait.c Mon Jan 16 16:29:19 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: t_condwait.c,v 1.4 2013/04/12 17:18:11 christos Exp $ */
+/* $NetBSD: t_condwait.c,v 1.5 2017/01/16 16:29:19 christos Exp $ */
/*
* Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -26,8 +26,9 @@
* POSSIBILITY OF SUCH DAMAGE.
*/
#include <sys/cdefs.h>
-__RCSID("$NetBSD: t_condwait.c,v 1.4 2013/04/12 17:18:11 christos Exp $");
+__RCSID("$NetBSD: t_condwait.c,v 1.5 2017/01/16 16:29:19 christos Exp $");
+#include <sys/time.h>
#include <errno.h>
#include <pthread.h>
#include <stdio.h>
@@ -40,6 +41,8 @@
#include "isqemu.h"
+#include "h_common.h"
+
#define WAITTIME 2 /* Timeout wait secound */
static const int debug = 1;
@@ -56,8 +59,8 @@
clck = *(clockid_t *)param;
- pthread_condattr_init(&attr);
- pthread_condattr_setclock(&attr, clck); /* MONOTONIC or MONOTONIC */
+ PTHREAD_REQUIRE(pthread_condattr_init(&attr));
+ PTHREAD_REQUIRE(pthread_condattr_setclock(&attr, clck));
pthread_cond_init(&cond, &attr);
ATF_REQUIRE_EQ((ret = pthread_mutex_lock(&m)), 0);
Home |
Main Index |
Thread Index |
Old Index