summaryrefslogtreecommitdiffstats
path: root/src/video_core
diff options
context:
space:
mode:
authorFernando Sahmkow <fsahmkow27@gmail.com>2024-01-05 03:47:48 +0100
committerLiam <byteslice@airmail.cc>2024-01-19 03:12:30 +0100
commita874ab0133459b713205a87738234fae03dc715b (patch)
treec206f6d744e7c61a9dc044013469b6e58100b2a4 /src/video_core
parentCore: Clang format and other small issues. (diff)
downloadyuzu-a874ab0133459b713205a87738234fae03dc715b.tar
yuzu-a874ab0133459b713205a87738234fae03dc715b.tar.gz
yuzu-a874ab0133459b713205a87738234fae03dc715b.tar.bz2
yuzu-a874ab0133459b713205a87738234fae03dc715b.tar.lz
yuzu-a874ab0133459b713205a87738234fae03dc715b.tar.xz
yuzu-a874ab0133459b713205a87738234fae03dc715b.tar.zst
yuzu-a874ab0133459b713205a87738234fae03dc715b.zip
Diffstat (limited to 'src/video_core')
-rw-r--r--src/video_core/memory_manager.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/video_core/memory_manager.cpp b/src/video_core/memory_manager.cpp
index ac1417fbc..b18b44e42 100644
--- a/src/video_core/memory_manager.cpp
+++ b/src/video_core/memory_manager.cpp
@@ -762,6 +762,9 @@ void MemoryManager::FlushCaching() {
}
const u8* MemoryManager::GetSpan(const GPUVAddr src_addr, const std::size_t size) const {
+ if (!IsContinuousRange(src_addr, size)) {
+ return nullptr;
+ }
auto dev_addr = GpuToCpuAddress(src_addr);
if (dev_addr) {
return memory.GetSpan(*dev_addr, size);