mirror of
https://github.com/momo5502/emulator.git
synced 2026-01-28 23:41:03 +00:00
Extract main module cache into module manager
This commit is contained in:
@@ -141,7 +141,7 @@ namespace
|
||||
};
|
||||
}
|
||||
|
||||
const auto& exe = *win_emu.process.executable;
|
||||
const auto& exe = *win_emu.mod_manager.executable;
|
||||
|
||||
const auto concise_logging = options.concise_logging;
|
||||
|
||||
@@ -154,7 +154,7 @@ namespace
|
||||
|
||||
auto read_handler = [&, section, concise_logging](const uint64_t address, size_t, uint64_t) {
|
||||
const auto rip = win_emu.emu().read_instruction_pointer();
|
||||
if (win_emu.mod_manager.find_by_address(rip) != win_emu.process.executable)
|
||||
if (win_emu.mod_manager.find_by_address(rip) != win_emu.mod_manager.executable)
|
||||
{
|
||||
return;
|
||||
}
|
||||
@@ -174,7 +174,7 @@ namespace
|
||||
|
||||
const auto write_handler = [&, section, concise_logging](const uint64_t address, size_t, uint64_t) {
|
||||
const auto rip = win_emu.emu().read_instruction_pointer();
|
||||
if (win_emu.mod_manager.find_by_address(rip) != win_emu.process.executable)
|
||||
if (win_emu.mod_manager.find_by_address(rip) != win_emu.mod_manager.executable)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@ emulator_hook* watch_object(windows_emulator& emu, const std::set<std::string, s
|
||||
[i = std::move(info), object, &emu, cache_logging, modules](const uint64_t address, size_t, uint64_t) {
|
||||
const auto rip = emu.emu().read_instruction_pointer();
|
||||
const auto* mod = emu.mod_manager.find_by_address(rip);
|
||||
const auto is_main_access = mod == emu.process.executable || modules.contains(mod->name);
|
||||
const auto is_main_access = mod == emu.mod_manager.executable || modules.contains(mod->name);
|
||||
|
||||
if (!emu.verbose_calls && !is_main_access)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user