in MakeContextCurrent() use old display pointer for __glXSetupForCommand(), bug 8443
authorBrian Paul <brian.paul@tungstengraphics.com>
Wed, 4 Oct 2006 16:22:24 +0000 (16:22 +0000)
committerBrian Paul <brian.paul@tungstengraphics.com>
Wed, 4 Oct 2006 16:22:24 +0000 (16:22 +0000)
src/glx/x11/glxext.c

index d4edf6d..ab2795e 100644 (file)
@@ -1582,7 +1582,7 @@ USED static Bool MakeContextCurrent(Display *dpy, GLXDrawable draw,
     }
 
     oldGC = __glXGetCurrentContext();
-    oldOpcode = (gc == oldGC) ? opcode : __glXSetupForCommand(dpy);
+    oldOpcode = (gc == oldGC) ? opcode : __glXSetupForCommand(oldGC->currentDpy);
     if (!oldOpcode) {
        return GL_FALSE;
     }