HackStudio: Use ProcessInspector instead of DebugSession where possible

This commit is contained in:
Itamar 2021-11-19 16:13:07 +02:00 committed by Linus Groh
commit 94d68583fb
Notes: sideshowbarker 2024-07-18 00:57:23 +09:00
8 changed files with 29 additions and 21 deletions

View file

@ -8,10 +8,10 @@
namespace Debug::StackFrameUtils {
Optional<StackFrameInfo> get_info(DebugSession const& session, FlatPtr current_ebp)
Optional<StackFrameInfo> get_info(ProcessInspector const& inspector, FlatPtr current_ebp)
{
auto return_address = session.peek(reinterpret_cast<u32*>(current_ebp + sizeof(FlatPtr)));
auto next_ebp = session.peek(reinterpret_cast<u32*>(current_ebp));
auto return_address = inspector.peek(reinterpret_cast<u32*>(current_ebp + sizeof(FlatPtr)));
auto next_ebp = inspector.peek(reinterpret_cast<u32*>(current_ebp));
if (!return_address.has_value() || !next_ebp.has_value())
return {};