From a88a34d46be79c128a1b289191505fc46a95288e Mon Sep 17 00:00:00 2001 From: Kenzzer <14257866+kenzzer@users.noreply.github.com> Date: Tue, 29 Apr 2025 20:17:46 +0000 Subject: [PATCH] Fix erroneous definition for khook global var --- core/ISmmPlugin.h | 6 +++--- third_party/khook | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/core/ISmmPlugin.h b/core/ISmmPlugin.h index 86c226c..5693b6e 100644 --- a/core/ISmmPlugin.h +++ b/core/ISmmPlugin.h @@ -494,7 +494,7 @@ class IKHook; ISmmAPI *g_SMAPI = NULL; \ ISmmPlugin *g_PLAPI = NULL; \ PluginId g_PLID = (PluginId)0; \ - KHook::IKHook* __exported__khook = nullptr; \ + namespace KHook { KHook::IKHook* __exported__khook = nullptr; } \ PL_EXPOSURE_FUNC(name, var) @@ -506,7 +506,7 @@ class IKHook; * to use values like g_SHPtr in other files. */ #define PLUGIN_GLOBALVARS() \ - extern KHook::IKHook* __exported__khook; \ + namespace KHooK { extern KHook::IKHook* __exported__khook; } \ extern ISmmAPI *g_SMAPI; \ extern ISmmPlugin *g_PLAPI; \ extern PluginId g_PLID; @@ -516,7 +516,7 @@ class IKHook; */ #define PLUGIN_SAVEVARS() \ g_SMAPI = ismm; \ - __exported__khook = static_cast(ismm->MetaFactory(MMIFACE_KHOOK, nullptr, nullptr)); \ + KHook::__exported__khook = static_cast(ismm->MetaFactory(MMIFACE_KHOOK, nullptr, nullptr)); \ g_PLAPI = static_cast(this); \ g_PLID = id; diff --git a/third_party/khook b/third_party/khook index b95ce7d..dc05996 160000 --- a/third_party/khook +++ b/third_party/khook @@ -1 +1 @@ -Subproject commit b95ce7df00cf3bbcbaf4d65a60c1d55d2a3b9c8f +Subproject commit dc059964c1ec674c18ee23c90b29800184fb07a8