fix: add l2.bin to valid process name

This commit is contained in:
Иванов Иван 2024-08-15 20:14:20 +02:00
parent 2943f7a50b
commit 46c877f036

View File

@ -44,11 +44,13 @@ BOOL APIENTRY DllMain(HMODULE hModule,
const int processId = GetCurrentProcessId();
const std::string& processName = InjectLibrary::GetCurrentProcessName();
const bool isLineageProcess = processName == "l2.exe" || processName == "l2.bin";
switch (ul_reason_for_call)
{
case DLL_PROCESS_ATTACH:
injector.SetHook(hModule);
if (processName == "l2.exe") {
if (isLineageProcess) {
ConfigLogger(hModule);
InjectLibrary::StopCurrentProcess();
@ -58,7 +60,7 @@ BOOL APIENTRY DllMain(HMODULE hModule,
}
break;
case DLL_PROCESS_DETACH:
if (processName == "l2.exe") {
if (isLineageProcess) {
InjectLibrary::StopCurrentProcess();
application.Stop();
InjectLibrary::StartCurrentProcess();