Changeset 6951 in vbox for trunk/include
- Timestamp:
- Feb 14, 2008 2:09:52 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/iprt/thread.h
r6946 r6951 374 374 375 375 /** 376 * Thread termination callback for destroying a non-zero TLS entry. 377 * 378 * @remarks It is not permittable to use any RTTls APIs at this time. Doing so 379 * may lead to endless loops, crashes, and other bad stuff. 380 * 381 * @param pvValue The current value. 382 */ 383 typedef DECLCALLBACK(void) FNRTTLSDTOR(void *pvValue); 384 /** Pointer to a FNRTTLSDTOR. */ 385 typedef FNRTTLSDTOR *PFNRTTLSDTOR; 386 387 /** 376 388 * Allocates a TLS entry. 377 389 * … … 385 397 * 386 398 * @returns IPRT status code. 387 * @param piTls Where to store the index of the allocated TLS entry. 388 * This is set to NIL_RTTLS on failure. 389 */ 390 RTR3DECL(int) RTTlsAllocEx(PRTTLS piTls); 399 * @retval VERR_NOT_SUPPORTED if pfnDestructor is non-NULL and the platform 400 * doesn't support this feature. 401 * 402 * @param piTls Where to store the index of the allocated TLS entry. 403 * This is set to NIL_RTTLS on failure. 404 * @param pfnDestructor Optional callback function for cleaning up on 405 * thread termination. WARNING! This feature may not 406 * be implemented everywhere. 407 */ 408 RTR3DECL(int) RTTlsAllocEx(PRTTLS piTls, PFNRTTLSDTOR pfnDestructor); 391 409 392 410 /** … … 427 445 RTR3DECL(int) RTTlsSet(RTTLS iTls, void *pvValue); 428 446 429 /**430 * Thread termination callback for destroying a non-zero TLS entry.431 *432 * Registered and deregisterd by RTTlsSetDestructor().433 *434 * @remarks It is not permittable to use any RTTls APIs at this time. Doing so435 * may lead to endless loops, crashes, and other bad stuff.436 *437 * @param pvValue The current value.438 */439 typedef DECLCALLBACK(void) FNRTTLSDTOR(void *pvValue);440 /** Pointer to a FNRTTLSDTOR. */441 typedef FNRTTLSDTOR *PFNRTTLSDTOR;442 443 /**444 * Register a thread termination destructor for a TLS entry.445 *446 * The destructor function will be called when a thread terminates447 * in a normal fashion and the TLS entry iTls of that thread is448 * not NULL.449 *450 * @remarks This is an optional feature and may therefore not be implemented451 * on all platforms. VERR_NOT_SUPPORTED is returned then.452 *453 * @returns IPRT status code.454 * @retval VERR_NOT_SUPPORTED if not supported on this platform.455 *456 * @param iTls The index of the TLS entry.457 * @param pfnDestructor Callback function. Use NULL to unregister a previously458 * registered destructor.459 *460 */461 RTR3DECL(int) RTTlsSetDestructor(RTTLS iTls, PFNRTTLSDTOR pfnDestructor);462 463 /**464 * Get pointer to the destructor function registered for the given TLS entry.465 *466 * @remarks This may not necessarily be implemented even if RTTlsSetDestructor is.467 *468 * @returns IPRT status code.469 * @retval VERR_NOT_SUPPORTED if not supported on this platform.470 *471 * @param iTls The index of the TLS entry.472 * @param ppfnDestructor Where to store the destructor address.473 */474 PFNRTTLSDTOR RTTlsGetDestructor(RTTLS iTls, PFNRTTLSDTOR *ppfnDestructor);475 476 447 /** @} */ 477 448
Note:
See TracChangeset
for help on using the changeset viewer.