We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d754ae3 commit fae7468Copy full SHA for fae7468
gfx/drivers_context/cocoa_gl_ctx.m
@@ -139,6 +139,13 @@ void cocoa_gl_gfx_ctx_update(void)
139
#if defined(HAVE_COCOATOUCH)
140
void *glkitview_init(void)
141
{
142
+ /* Delete the old view's framebuffer while we may still have a valid
143
+ * GL context. Without this, the subsequent release of the old GLKView
144
+ * triggers _deleteFramebuffer during dealloc, which calls
145
+ * glPushGroupMarkerEXT with no current context and crashes. */
146
+ if (glk_view)
147
+ [glk_view deleteDrawable];
148
+
149
glk_view = [GLKView new];
150
#if TARGET_OS_IOS
151
glk_view.multipleTouchEnabled = YES;
0 commit comments