aboutsummaryrefslogtreecommitdiff
path: root/src/yuzu/bootmanager.cpp
diff options
context:
space:
mode:
authorJames Rowe <jroweboy@gmail.com>2020-03-30 14:52:46 -0600
committerJames Rowe <jroweboy@gmail.com>2020-03-30 14:57:42 -0600
commitf1da3ec584e5956c8090ac9a958447e4f5e78da2 (patch)
treee68a313e919cfce944bf9857038502b97d4b35e2 /src/yuzu/bootmanager.cpp
parentcf9c94d4017120b618194a720942ef4e5c8289bd (diff)
Frontend: Don't call DoneCurrent if the context isnt already current
Diffstat (limited to 'src/yuzu/bootmanager.cpp')
-rw-r--r--src/yuzu/bootmanager.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/yuzu/bootmanager.cpp b/src/yuzu/bootmanager.cpp
index 4e9ced8baf..eaded2640c 100644
--- a/src/yuzu/bootmanager.cpp
+++ b/src/yuzu/bootmanager.cpp
@@ -141,7 +141,7 @@ public:
}
~OpenGLSharedContext() {
- context->doneCurrent();
+ DoneCurrent();
}
void SwapBuffers() override {
@@ -156,6 +156,9 @@ public:
}
void DoneCurrent() override {
+ if (!is_current) {
+ return;
+ }
context->doneCurrent();
is_current = false;
}