Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
RenardDev authored Jul 30, 2024
1 parent 10d7331 commit 53d9d3e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Detours.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7540,7 +7540,7 @@ namespace Detours {
} else if (ReadOperand.Type == RD_OP_REG) {
ULONG_PTR unValue = GetRegisterValue(pCTX, ReadOperand.Info.Register.Reg, ReadOperand.Info.Register.Size);
if (reinterpret_cast<ULONG_PTR>(pAddress) == unValue) {
SetRegisterValue(pCTX, ReadOperand.Info.Register.Reg, ReadOperand.Info.Register.Size, unValue);
SetRegisterValue(pCTX, ReadOperand.Info.Register.Reg, ReadOperand.Info.Register.Size, reinterpret_cast<size_t>(pNewAddress));
}
} else if (ReadOperand.Type == RD_OP_MEM) {
#ifdef _M_X64
Expand Down Expand Up @@ -7611,7 +7611,7 @@ namespace Detours {
} else if (WriteOperand.Type == RD_OP_REG) {
ULONG_PTR unValue = GetRegisterValue(pCTX, WriteOperand.Info.Register.Reg, WriteOperand.Info.Register.Size);
if (reinterpret_cast<ULONG_PTR>(pAddress) == unValue) {
SetRegisterValue(pCTX, WriteOperand.Info.Register.Reg, WriteOperand.Info.Register.Size, unValue);
SetRegisterValue(pCTX, WriteOperand.Info.Register.Reg, WriteOperand.Info.Register.Size, reinterpret_cast<size_t>(pNewAddress));
}
} else if (WriteOperand.Type == RD_OP_MEM) {
#ifdef _M_X64
Expand Down

0 comments on commit 53d9d3e

Please sign in to comment.