copy disasm for internal_detour_copy_instruction
This commit is contained in:
parent
4963fbc33c
commit
e04585377a
5 changed files with 702 additions and 4 deletions
|
|
@ -13,6 +13,7 @@
|
|||
#endif
|
||||
|
||||
#include "detours_internal.h"
|
||||
#include "detours_disasm.h"
|
||||
|
||||
#include "arm64/detours_arm64.h"
|
||||
|
||||
|
|
@ -767,7 +768,7 @@ mach_error_t detour_attach_ex(detour_func_t* inout_pointer, detour_func_t detour
|
|||
int32_t extra_len = 0;
|
||||
|
||||
DETOUR_TRACE((" copy instruction src=%p, dest=%p\n", src, trampoline_code));
|
||||
src = (uint8_t*)internal_detour_copy_instruction(trampoline_code, (void**)&trampoline_code_limit, src, nullptr, &extra_len);
|
||||
src = (uint8_t*)internal_detour_copy_instruction(trampoline_code, src, nullptr, &extra_len);
|
||||
DETOUR_TRACE((" after: src=%p (copied %d bytes)\n", src, (int)(src - curr_op)));
|
||||
trampoline_code += (src - curr_op) + extra_len;
|
||||
offset_target = (int32_t)(src - target);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue