summaryrefslogtreecommitdiffstats
path: root/src/core/gdbstub
diff options
context:
space:
mode:
authorLioncash <mathew1800@gmail.com>2019-11-26 22:29:34 +0100
committerLioncash <mathew1800@gmail.com>2019-11-27 03:55:39 +0100
commitb05bfc603689419dc515a656b9fc711d79994f13 (patch)
treebc0937d11bbe31458785a69478edbf11a720b0ae /src/core/gdbstub
parentcore/memory: Migrate over ZeroBlock() and CopyBlock() to the Memory class (diff)
downloadyuzu-b05bfc603689419dc515a656b9fc711d79994f13.tar
yuzu-b05bfc603689419dc515a656b9fc711d79994f13.tar.gz
yuzu-b05bfc603689419dc515a656b9fc711d79994f13.tar.bz2
yuzu-b05bfc603689419dc515a656b9fc711d79994f13.tar.lz
yuzu-b05bfc603689419dc515a656b9fc711d79994f13.tar.xz
yuzu-b05bfc603689419dc515a656b9fc711d79994f13.tar.zst
yuzu-b05bfc603689419dc515a656b9fc711d79994f13.zip
Diffstat (limited to 'src/core/gdbstub')
-rw-r--r--src/core/gdbstub/gdbstub.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/core/gdbstub/gdbstub.cpp b/src/core/gdbstub/gdbstub.cpp
index 78e44f3bd..1c74a44d8 100644
--- a/src/core/gdbstub/gdbstub.cpp
+++ b/src/core/gdbstub/gdbstub.cpp
@@ -969,13 +969,13 @@ static void ReadMemory() {
SendReply("E01");
}
- const auto& memory = Core::System::GetInstance().Memory();
+ auto& memory = Core::System::GetInstance().Memory();
if (!memory.IsValidVirtualAddress(addr)) {
return SendReply("E00");
}
std::vector<u8> data(len);
- Memory::ReadBlock(addr, data.data(), len);
+ memory.ReadBlock(addr, data.data(), len);
MemToGdbHex(reply, data.data(), len);
reply[len * 2] = '\0';
@@ -1057,7 +1057,9 @@ static bool CommitBreakpoint(BreakpointType type, VAddr addr, u64 len) {
breakpoint.active = true;
breakpoint.addr = addr;
breakpoint.len = len;
- Memory::ReadBlock(addr, breakpoint.inst.data(), breakpoint.inst.size());
+
+ auto& memory = Core::System::GetInstance().Memory();
+ memory.ReadBlock(addr, breakpoint.inst.data(), breakpoint.inst.size());
static constexpr std::array<u8, 4> btrap{0x00, 0x7d, 0x20, 0xd4};
if (type == BreakpointType::Execute) {