|
noexcept |
Joins the specified thread to the current one blocking until its completion.
[in] | thr | is an identifier of a thread to wait. The thread must not be previously attached or joined. |
[out] | res | is an optional pointer to a buffer, on output receiving a result code of the terminated thread. |
The function joins the thread identified by thr
with the current thread by blocking until the other thread has terminated. If the parameter res is not a null pointer, it stores the thread’s result code in the integer pointed to by res.
The termination of the other thread synchronizes with the completion of the chsv_thrd_join function. The thread identified by thr
shall not have been previously detached or joined with another thread.
The function implements a behaviour of the thrd_join function defined in the ISO/IEC 9899:2011 (aka C11) standard.