From 907bea6abb95d78c0393a89942a0f500b77e48bb Mon Sep 17 00:00:00 2001 From: LazyBumHorse Date: Mon, 12 Aug 2019 23:05:44 +0200 Subject: [PATCH] destroy leaked context --- gfx/drivers_context/x_ctx.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/gfx/drivers_context/x_ctx.c b/gfx/drivers_context/x_ctx.c index 38f9d9c362..57e3c82108 100644 --- a/gfx/drivers_context/x_ctx.c +++ b/gfx/drivers_context/x_ctx.c @@ -923,6 +923,9 @@ static bool gfx_ctx_x_set_video_mode(void *data, break; } + glXMakeContextCurrent(g_x11_dpy, None, None, NULL); + glXDestroyContext(g_x11_dpy, x->g_ctx); + RARCH_LOG("[GLX]: Not running Mesa, trying higher versions...\n"); } else