| 749 | } |
| 750 | |
| 751 | void WinDebugger::PhysRemoveBreakpoint(addr_target address) |
| 752 | { |
| 753 | BfLogDbg("PhysRemoveBreakpoint %p\n", address); |
| 754 | |
| 755 | uint8 origData; |
| 756 | DbgMemoryFlags flags = mDebugTarget->ReadOrigImageData(address, &origData, 1); |
| 757 | if ((flags & DbgMemoryFlags_Execute) == 0) |
| 758 | { |
| 759 | //BF_ASSERT("Failed" == 0); |
| 760 | return; |
| 761 | } |
| 762 | |
| 763 | SIZE_T dwReadBytes; |
| 764 | if (!WriteProcessMemory(mProcessInfo.hProcess, (void*)(intptr)address, &origData, 1, &dwReadBytes)) |
| 765 | { |
| 766 | int err = GetLastError(); |
| 767 | BfLogDbg("RemoveBreakpoint FAILED %p\n", address); |
| 768 | } |
| 769 | FlushInstructionCache(mProcessInfo.hProcess, (void*)(intptr)address, 1); |
| 770 | } |
| 771 | |
| 772 | void WinDebugger::RemoveBreakpoint(addr_target address) |
| 773 | { |
nothing calls this directly
no test coverage detected