aboutsummaryrefslogtreecommitdiff
path: root/src/core
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2020-11-26 01:27:24 -0800
committerGitHub <noreply@github.com>2020-11-26 01:27:24 -0800
commita20ffebc805f164c94ce712fd8219720b1eaeec7 (patch)
treeb11cb630a78fba7e611045462425ce929429a40c /src/core
parenta265c454f3d7de5cf31ec649c69aefa99c5311ae (diff)
parent00f2c7fbb97a893fba164fa366de6373090c3796 (diff)
Merge pull request #4975 from comex/invalid-syncpoint-id
nvdrv, video_core: Don't index out of bounds when given invalid syncpoint ID
Diffstat (limited to 'src/core')
-rw-r--r--src/core/hle/service/nvdrv/syncpoint_manager.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/core/hle/service/nvdrv/syncpoint_manager.h b/src/core/hle/service/nvdrv/syncpoint_manager.h
index 4168b6c7ed..d395c5d0bb 100644
--- a/src/core/hle/service/nvdrv/syncpoint_manager.h
+++ b/src/core/hle/service/nvdrv/syncpoint_manager.h
@@ -37,7 +37,7 @@ public:
* @returns The lower bound for the specified syncpoint.
*/
u32 GetSyncpointMin(u32 syncpoint_id) const {
- return syncpoints[syncpoint_id].min.load(std::memory_order_relaxed);
+ return syncpoints.at(syncpoint_id).min.load(std::memory_order_relaxed);
}
/**
@@ -46,7 +46,7 @@ public:
* @returns The upper bound for the specified syncpoint.
*/
u32 GetSyncpointMax(u32 syncpoint_id) const {
- return syncpoints[syncpoint_id].max.load(std::memory_order_relaxed);
+ return syncpoints.at(syncpoint_id).max.load(std::memory_order_relaxed);
}
/**