diff --git a/Source/Core/VideoCommon/Src/BPStructs.cpp b/Source/Core/VideoCommon/Src/BPStructs.cpp index add40d99c3..af263235cd 100644 --- a/Source/Core/VideoCommon/Src/BPStructs.cpp +++ b/Source/Core/VideoCommon/Src/BPStructs.cpp @@ -519,9 +519,8 @@ void BPWritten(const BPCmd& bp) for (u32 i = 0; i < tmem_cfg.preload_tile_info.count; ++i) { - // FIXME: Duplicate conditions. if (tmem_addr_even + TMEM_LINE_SIZE > TMEM_SIZE || - tmem_addr_even + TMEM_LINE_SIZE > TMEM_SIZE) + tmem_addr_odd + TMEM_LINE_SIZE > TMEM_SIZE) break; memcpy(texMem + tmem_addr_even, src_ptr, TMEM_LINE_SIZE); diff --git a/Source/Plugins/Plugin_VideoSoftware/Src/BPMemLoader.cpp b/Source/Plugins/Plugin_VideoSoftware/Src/BPMemLoader.cpp index f0674a96cc..f05f9f8b57 100644 --- a/Source/Plugins/Plugin_VideoSoftware/Src/BPMemLoader.cpp +++ b/Source/Plugins/Plugin_VideoSoftware/Src/BPMemLoader.cpp @@ -135,11 +135,10 @@ void SWBPWritten(int address, int newvalue) // AR and GB tiles are stored in separate TMEM banks => can't use a single memcpy for everything u32 tmem_addr_odd = tmem_cfg.preload_tmem_odd * TMEM_LINE_SIZE; - for (int i = 0; i < tmem_cfg.preload_tile_info.count; ++i) + for (unsigned int i = 0; i < tmem_cfg.preload_tile_info.count; ++i) { - // FIXME: Duplicate conditions if (tmem_addr_even + TMEM_LINE_SIZE > TMEM_SIZE || - tmem_addr_even + TMEM_LINE_SIZE > TMEM_SIZE) + tmem_addr_odd + TMEM_LINE_SIZE > TMEM_SIZE) break; memcpy(texMem + tmem_addr_even, src_ptr, TMEM_LINE_SIZE);