chsvlib
chsv helper source code

◆ chsv_tss_delete()

void Chusov::ExecutionControl::chsv_tss_delete ( chsv_tss_t  key)
noexcept

Deletes the specified key of the thread-specific storage (TSS) and releases any associated resources.

Parameters
[in]keyidentifies a key associated with the TSS.
Returns
The function returns nothing.

The function shall delete a thread-specific data key previously returned by chsv_tss_create. The thread-specific data values associated with key need not be NULL at the time the function is called. It is the responsibility of the application to free any application storage or perform any cleanup actions for data structures related to the deleted key or associated thread-specific data in any threads; this cleanup can be done either before or after pthread_key_delete is called. Any attempt to use key following the call results in undefined behaviour.

The function is callable from within destructor functions. No destructor functions are invoked by the function. Any destructor function that may have been associated with the key must no longer be called upon thread exit.

The function implements a behaviour of the tss_delete function defined in the ISO/IEC 9899:2011 (aka C11) standard.

See also
chsv_tss_create;
chsv_tss_get;
chsv_tss_set.