Fix OpenGLSafePoint guard

qScopeGuard runs the method when the function goes out of scope. Without
a local variable this is immediately.
This commit is contained in:
David Edmundson 2022-01-26 22:19:31 +00:00
parent 6432f29e9f
commit b3abe7526b

View file

@ -167,7 +167,7 @@ bool Compositor::attemptOpenGLCompositing()
}
kwinApp()->platform()->createOpenGLSafePoint(Platform::OpenGLSafePoint::PreInit);
qScopeGuard([]() {
auto safePointScope = qScopeGuard([]() {
kwinApp()->platform()->createOpenGLSafePoint(Platform::OpenGLSafePoint::PostInit);
});