mirror of
https://github.com/WPMGPRoSToTeMa/SafeNameAndChat.git
synced 2025-02-04 18:00:31 +03:00
Forgot PLID in LOG_CONSOLE
This commit is contained in:
parent
0cff1bfa8f
commit
32e0562f50
10
Main.cpp
10
Main.cpp
@ -382,19 +382,19 @@ void Init() {
|
|||||||
|
|
||||||
dlclose(handle);
|
dlclose(handle);
|
||||||
|
|
||||||
LOG_CONSOLE("It's ok");
|
LOG_CONSOLE(PLID, "It's ok");
|
||||||
|
|
||||||
uintptr_t addr = (uintptr_t)g_engfuncs.pfnMessageEnd;
|
uintptr_t addr = (uintptr_t)g_engfuncs.pfnMessageEnd;
|
||||||
mprotect((void*)(addr/PAGESIZE*PAGESIZE), 5 + addr%PAGESIZE, PROT_EXEC | PROT_READ | PROT_WRITE);
|
mprotect((void*)(addr/PAGESIZE*PAGESIZE), 5 + addr%PAGESIZE, PROT_EXEC | PROT_READ | PROT_WRITE);
|
||||||
LOG_CONSOLE("I'm fine");
|
LOG_CONSOLE(PLID, "I'm fine");
|
||||||
memcpy(g_originalBytes, (void*)g_engfuncs.pfnMessageEnd, 5);
|
memcpy(g_originalBytes, (void*)g_engfuncs.pfnMessageEnd, 5);
|
||||||
LOG_CONSOLE("Are you ok guys?");
|
LOG_CONSOLE(PLID, "Are you ok guys?");
|
||||||
g_patchedBytes[0] = char(0xE9);
|
g_patchedBytes[0] = char(0xE9);
|
||||||
*(uint32_t*)&g_patchedBytes[1] = (uint32_t)&PF_MessageEnd_I - ((uint32_t)g_engfuncs.pfnMessageEnd + 5);
|
*(uint32_t*)&g_patchedBytes[1] = (uint32_t)&PF_MessageEnd_I - ((uint32_t)g_engfuncs.pfnMessageEnd + 5);
|
||||||
memcpy((void*)g_engfuncs.pfnMessageEnd, g_patchedBytes, 5);
|
memcpy((void*)g_engfuncs.pfnMessageEnd, g_patchedBytes, 5);
|
||||||
LOG_CONSOLE("Wow");
|
LOG_CONSOLE(PLID, "Wow");
|
||||||
mprotect((void*)(addr/PAGESIZE*PAGESIZE), 5 + addr%PAGESIZE, PROT_EXEC | PROT_READ);
|
mprotect((void*)(addr/PAGESIZE*PAGESIZE), 5 + addr%PAGESIZE, PROT_EXEC | PROT_READ);
|
||||||
LOG_CONSOLE("Hmm");
|
LOG_CONSOLE(PLID, "Hmm");
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user