summaryrefslogtreecommitdiff
path: root/src/glx/x11/glxcurrent.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/glx/x11/glxcurrent.c')
-rw-r--r--src/glx/x11/glxcurrent.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/glx/x11/glxcurrent.c b/src/glx/x11/glxcurrent.c
index 01f4233241..d44e0dd1fc 100644
--- a/src/glx/x11/glxcurrent.c
+++ b/src/glx/x11/glxcurrent.c
@@ -457,7 +457,7 @@ MakeContextCurrent(Display * dpy, GLXDrawable draw,
&dummy_reply);
}
#ifdef GLX_DIRECT_RENDERING
- else if (oldGC->driContext) {
+ else if (oldGC->driContext && oldGC != gc) {
oldGC->driContext->unbindContext(oldGC->driContext);
}
#endif