summaryrefslogtreecommitdiff
path: root/nuttx/examples/ostest/barrier.c
diff options
context:
space:
mode:
Diffstat (limited to 'nuttx/examples/ostest/barrier.c')
-rw-r--r--nuttx/examples/ostest/barrier.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/nuttx/examples/ostest/barrier.c b/nuttx/examples/ostest/barrier.c
index 731eaa817..2b6755c9d 100644
--- a/nuttx/examples/ostest/barrier.c
+++ b/nuttx/examples/ostest/barrier.c
@@ -53,7 +53,7 @@ static void *barrier_func(void *parameter)
usleep(500*1000);
#endif
- /* Take the semaphore */
+ /* Wait at the barrier until all threads are synchronized. */
printf("barrier_func: Thread %d calling pthread_barrier_wait()\n", id);
status = pthread_barrier_wait(&barrier);
@@ -99,6 +99,7 @@ void barrier_test(void)
{
printf("barrier_test: pthread_barrierattr_init failed, status=%d\n", status);
}
+
/* Create the barrier */
status = pthread_barrierattr_init(&barrierattr);