Browse Source

All: Disabled hooks on processes other than Explorer

Because anticheats really hate DLLs that inject to games, let alone DLLs that hook existing functions. This was made as an attempt to fix #2267.
pull/2331/head 22621.2361.58.4_acc0131
Amrsatrio 2 years ago
parent
commit
acc0131e77
  1. 5
      ExplorerPatcher/dllmain.c

5
ExplorerPatcher/dllmain.c

@ -10705,7 +10705,7 @@ DWORD Inject(BOOL bIsExplorer) @@ -10705,7 +10705,7 @@ DWORD Inject(BOOL bIsExplorer)
Explorer_RefreshUI(99);
#ifdef _WIN64
// if (bIsExplorer)
if (bIsExplorerProcess)
{
funchook = funchook_create();
// printf("funchook create %d\n", funchook != 0);
@ -10890,11 +10890,14 @@ DWORD Inject(BOOL bIsExplorer) @@ -10890,11 +10890,14 @@ DWORD Inject(BOOL bIsExplorer)
if (!bIsExplorer)
{
#ifdef _WIN64
if (bIsExplorerProcess)
{
rv = funchook_install(funchook, 0);
if (rv != 0)
{
printf("Failed to install hooks. rv = %d\n", rv);
}
}
#endif
return 0;
}

Loading…
Cancel
Save