2 .\" This file and its contents are supplied under the terms of the
3 .\" Common Development and Distribution License ("CDDL"), version 1.0.
4 .\" You may only use this file in accordance with the terms of version
7 .\" A full copy of the text of the CDDL should have accompanied this
8 .\" source. A copy of the CDDL is also available via the Internet at
9 .\" http://www.illumos.org/license/CDDL.
12 .\" Copyright 2016 Joyent, Inc.
19 .Nd wait for thread termination
30 function suspends the exection of the current thread and waits for the
33 to terminate and stores the exit status, as set by a call to
42 argument must be a member of the current process and it cannot be
46 has already terminated and another caller has not called
48 then the exit status will be returned to the caller without blocking
49 execution of the thread.
51 If multiple threads call
53 on the same thread, then both will be suspended until that thread
54 terminates; however, only one thread will return successfully and obtain
55 the actual status and the other will instead return with an error.
57 For additional information on the thread joining interfaces supported by
63 Upon successful completion, the
69 is a non-null pointer, it will be filled in with the exit status of
74 .Sh INTERFACE STABILITY