diff options
author | Lioncash <mathew1800@gmail.com> | 2020-04-15 22:20:03 -0400 |
---|---|---|
committer | Lioncash <mathew1800@gmail.com> | 2020-04-15 22:20:06 -0400 |
commit | 3a60f19eaf71b9eead03a51a4af4beaebc75433f (patch) | |
tree | 91a06d57c24dec6bda208f7e52eabeb8b3f74291 /src | |
parent | e33196d4e7687dd29636decd4b52e01b10fe8984 (diff) |
gl_query_cache: Resolve use-after-move in CachedQuery move assignment operator
Avoids potential invalid junk data from being read.
Diffstat (limited to 'src')
-rw-r--r-- | src/video_core/renderer_opengl/gl_query_cache.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/video_core/renderer_opengl/gl_query_cache.cpp b/src/video_core/renderer_opengl/gl_query_cache.cpp index f12e9f55f..d7ba57aca 100644 --- a/src/video_core/renderer_opengl/gl_query_cache.cpp +++ b/src/video_core/renderer_opengl/gl_query_cache.cpp @@ -94,9 +94,9 @@ CachedQuery::CachedQuery(CachedQuery&& rhs) noexcept : VideoCommon::CachedQueryBase<HostCounter>(std::move(rhs)), cache{rhs.cache}, type{rhs.type} {} CachedQuery& CachedQuery::operator=(CachedQuery&& rhs) noexcept { - VideoCommon::CachedQueryBase<HostCounter>::operator=(std::move(rhs)); cache = rhs.cache; type = rhs.type; + CachedQueryBase<HostCounter>::operator=(std::move(rhs)); return *this; } |