diff options
author | Juan José <soyjuanarbol@gmail.com> | 2024-11-26 08:44:38 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-11-26 08:44:38 -0500 |
commit | 556a0f1f0fd1c89c88738e49ebcc0d75a00a3384 (patch) | |
tree | b28385c20a94f8449c9cac050e4ab3be5eb84b2d /docs/src | |
parent | b1d30f9489771a295c1d9b06402e49a77b3e91e6 (diff) | |
download | libuv-556a0f1f0fd1c89c88738e49ebcc0d75a00a3384.tar.gz libuv-556a0f1f0fd1c89c88738e49ebcc0d75a00a3384.zip |
unix,win: add support for detached threads (#4621)
This commit introduces the `uv_thread_detach` for thread detaching,
allowing threads to be detached state on both UNIX and Windows platforms.
Signed-off-by: Juan José Arboleda <soyjuanarbol@gmail.com>
Diffstat (limited to 'docs/src')
-rw-r--r-- | docs/src/threading.rst | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/docs/src/threading.rst b/docs/src/threading.rst index 883218fa..72f8bae0 100644 --- a/docs/src/threading.rst +++ b/docs/src/threading.rst @@ -78,6 +78,14 @@ Threads .. versionchanged:: 1.4.1 returns a UV_E* error code on failure +.. c:function:: int uv_thread_detach(uv_thread_t* tid) + + Detaches a thread. Detached threads automatically release their + resources upon termination, eliminating the need for the application to + call `uv_thread_join`. + + .. versionadded:: 1.50.0 + .. c:function:: int uv_thread_create_ex(uv_thread_t* tid, const uv_thread_options_t* params, uv_thread_cb entry, void* arg) Like :c:func:`uv_thread_create`, but additionally specifies options for creating a new thread. |