diff --git a/lib/libimhex/include/hex/providers/memory_provider.hpp b/lib/libimhex/include/hex/providers/memory_provider.hpp index ff24727b8..594fa3788 100644 --- a/lib/libimhex/include/hex/providers/memory_provider.hpp +++ b/lib/libimhex/include/hex/providers/memory_provider.hpp @@ -36,6 +36,14 @@ namespace hex::prv { [[nodiscard]] std::string getTypeName() const override { return "MemoryProvider"; } + std::pair getRegionValidity(u64 address) const { + address -= this->getBaseAddress(); + + if (address < this->getActualSize()) + return { Region { this->getBaseAddress() + address, this->getActualSize() - address }, true }; + else + return { Region::Invalid(), false }; + } private: void renameFile();