mirror of
https://github.com/WPMGPRoSToTeMa/SafeNameAndChat.git
synced 2025-01-29 20:27:54 +03:00
Added some additional tests for linux
This commit is contained in:
parent
32e0562f50
commit
7a9ecbe842
4
Main.cpp
4
Main.cpp
@ -372,13 +372,17 @@ void Init() {
|
|||||||
memcpy(g_engfuncs.pfnMessageEnd, g_patchedBytes, 5);
|
memcpy(g_engfuncs.pfnMessageEnd, g_patchedBytes, 5);
|
||||||
VirtualProtect(g_engfuncs.pfnMessageEnd, 5, oldProtect, &oldProtect);
|
VirtualProtect(g_engfuncs.pfnMessageEnd, 5, oldProtect, &oldProtect);
|
||||||
#else
|
#else
|
||||||
|
LOG_CONSOLE(PLID, "Pre hello");
|
||||||
Dl_info dlinfo;
|
Dl_info dlinfo;
|
||||||
dladdr((void*)g_engfuncs.pfnMessageEnd, &dlinfo);
|
dladdr((void*)g_engfuncs.pfnMessageEnd, &dlinfo);
|
||||||
|
LOG_CONSOLE(PLID, "Hello");
|
||||||
|
|
||||||
auto handle = dlopen(dlinfo.dli_fname, RTLD_NOW);
|
auto handle = dlopen(dlinfo.dli_fname, RTLD_NOW);
|
||||||
|
LOG_CONSOLE(PLID, "How are you?");
|
||||||
|
|
||||||
g_msgBuffer = (decltype(g_msgBuffer))dlsym(handle, "gMsgBuffer");
|
g_msgBuffer = (decltype(g_msgBuffer))dlsym(handle, "gMsgBuffer");
|
||||||
g_msgType = (decltype(g_msgType))dlsym(handle, "gMsgType");
|
g_msgType = (decltype(g_msgType))dlsym(handle, "gMsgType");
|
||||||
|
LOG_CONSOLE(PLID, "It should be here");
|
||||||
|
|
||||||
dlclose(handle);
|
dlclose(handle);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user