summaryrefslogtreecommitdiff
path: root/src/core
diff options
context:
space:
mode:
authorGravatar liamwhite2023-06-01 09:05:42 -0400
committerGravatar GitHub2023-06-01 09:05:42 -0400
commit00b6bef65a1d4e2a78165ec27519d14637c97401 (patch)
tree28bf757e3c207a3d529a62a81100e8768f2227d7 /src/core
parentMerge pull request #10474 from GPUCode/you-left-me-waiting (diff)
parentFix incorrect id check and potential out of bounds lookup (diff)
downloadyuzu-00b6bef65a1d4e2a78165ec27519d14637c97401.tar.gz
yuzu-00b6bef65a1d4e2a78165ec27519d14637c97401.tar.xz
yuzu-00b6bef65a1d4e2a78165ec27519d14637c97401.zip
Merge pull request #10530 from Kelebek1/syncpt_oob
Fix incorrect syncpt id bounds check and potential out of bounds lookup
Diffstat (limited to 'src/core')
-rw-r--r--src/core/hle/service/nvdrv/core/syncpoint_manager.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/core/hle/service/nvdrv/core/syncpoint_manager.cpp b/src/core/hle/service/nvdrv/core/syncpoint_manager.cpp
index aba51d280..c4c4c2593 100644
--- a/src/core/hle/service/nvdrv/core/syncpoint_manager.cpp
+++ b/src/core/hle/service/nvdrv/core/syncpoint_manager.cpp
@@ -64,7 +64,7 @@ void SyncpointManager::FreeSyncpoint(u32 id) {
64} 64}
65 65
66bool SyncpointManager::IsSyncpointAllocated(u32 id) const { 66bool SyncpointManager::IsSyncpointAllocated(u32 id) const {
67 return (id <= SyncpointCount) && syncpoints[id].reserved; 67 return (id < SyncpointCount) && syncpoints[id].reserved;
68} 68}
69 69
70bool SyncpointManager::HasSyncpointExpired(u32 id, u32 threshold) const { 70bool SyncpointManager::HasSyncpointExpired(u32 id, u32 threshold) const {