thrd_join - cppreference.com (original) (raw)

Blocks the current thread until the thread identified by thr finishes execution.

If res is not a null pointer, the result code of the thread is put to the location pointed to by res.

The termination of the thread synchronizes-with the completion of this function.

The behavior is undefined if the thread was previously detached or joined by another thread.

[edit] Parameters

thr - identifier of the thread to join
res - location to put the result code to

[edit] Return value

thrd_success if successful, thrd_error otherwise.

[edit] References

[edit] See also