This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// @source: http://www.unknowncheats.me/forum/c-and-c/84146-tls-callback-tutorial.html | |
#include "windows.h" | |
#include <stdio.h> | |
void NTAPI __stdcall TLSCallbacks(PVOID DllHandle, DWORD dwReason, PVOID Reserved); | |
//linker spec | |
#ifdef _M_IX86 | |
#pragma comment (linker, "/INCLUDE:__tls_used") | |
#pragma comment (linker, "/INCLUDE:__tls_callback") | |
#else |