1 /* _PDCLIB_runTlsCallbacks( void *, DWORD, PVOID )
3 This file is part of the Public Domain C Library (PDCLib).
4 Permission is granted to use, modify, and / or redistribute at will.
11 extern PIMAGE_TLS_CALLBACK __crt_xl_start__;
13 __attribute__((section(".CRT$XLZZZ")))
15 __declspec(allocate(".CRT$XLZZZ"))
17 PIMAGE_TLS_CALLBACK __crt_xl_end__ = NULL;
19 /* Runs all TLS callbacks registered in the executable
22 void NTAPI _PDCLIB_runTlsCallbacks(void * image, DWORD reason, PVOID pv);
23 void NTAPI _PDCLIB_runTlsCallbacks(void * image, DWORD reason, PVOID pv)
25 PIMAGE_TLS_CALLBACK * pcb = &__crt_xl_start__;
27 while(*pcb) (*(pcb++))(image, reason, pv);
32 #include "_PDCLIB_test.h"
34 /* Tested in tss_get.c */