mirror of
https://github.com/HIllya51/LunaTranslator.git
synced 2024-12-28 08:04:13 +08:00
noinline
This commit is contained in:
parent
1b28a2cfad
commit
69c422090f
@ -2,10 +2,12 @@
|
|||||||
#include "MinHook.h"
|
#include "MinHook.h"
|
||||||
void HIJACK();
|
void HIJACK();
|
||||||
void detachall();
|
void detachall();
|
||||||
|
std::unordered_map<uint64_t, std::pair<JITTYPE, uintptr_t>> emuaddr2jitaddr;
|
||||||
|
std::unordered_map<uintptr_t, std::pair<JITTYPE, uint64_t>> jitaddr2emuaddr;
|
||||||
HMODULE hLUNAHOOKDLL;
|
HMODULE hLUNAHOOKDLL;
|
||||||
WinMutex viewMutex;
|
WinMutex viewMutex;
|
||||||
CommonSharedMem *commonsharedmem;
|
CommonSharedMem *commonsharedmem;
|
||||||
Synchronized<std::map<uint64_t, std::pair<std::string, HookParam>>> delayinserthook; // 谜之这个必须在这里定义(可以extern+cpp里定义,或者只在这里写),不能在main.h里inline定义,否则会在v141_xp上编译后会崩。
|
Synchronized<std::map<uint64_t, std::pair<std::string, HookParam>>> delayinserthook;
|
||||||
namespace
|
namespace
|
||||||
{
|
{
|
||||||
AutoHandle<> hookPipe = INVALID_HANDLE_VALUE,
|
AutoHandle<> hookPipe = INVALID_HANDLE_VALUE,
|
||||||
|
@ -18,8 +18,10 @@ inline SearchParam spDefault;
|
|||||||
|
|
||||||
// EOF
|
// EOF
|
||||||
int HookStrLen(HookParam *, BYTE *data);
|
int HookStrLen(HookParam *, BYTE *data);
|
||||||
inline std::unordered_map<uint64_t, std::pair<JITTYPE, uintptr_t>> emuaddr2jitaddr;
|
|
||||||
inline std::unordered_map<uintptr_t, std::pair<JITTYPE, uint64_t>> jitaddr2emuaddr;
|
// v141_xp上,定义inline std::map会直接导致dll detach后发生崩溃。
|
||||||
|
extern std::unordered_map<uint64_t, std::pair<JITTYPE, uintptr_t>> emuaddr2jitaddr;
|
||||||
|
extern std::unordered_map<uintptr_t, std::pair<JITTYPE, uint64_t>> jitaddr2emuaddr;
|
||||||
void jitaddraddr(uint64_t em_addr, uintptr_t jitaddr, JITTYPE);
|
void jitaddraddr(uint64_t em_addr, uintptr_t jitaddr, JITTYPE);
|
||||||
|
|
||||||
void context_get(hook_stack *, PCONTEXT);
|
void context_get(hook_stack *, PCONTEXT);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user