diff --git a/glx/glxcmds.c b/glx/glxcmds.c index 189b5d9131370f136b2a374fb9b9ea8f81451768..1e2061d898dc3cde2e426f6b3c938bcd9d94d49f 100644 --- a/glx/glxcmds.c +++ b/glx/glxcmds.c @@ -284,6 +284,15 @@ DoCreateContext(__GLXclientState * cl, GLXContextID gcId, */ isDirect = GL_FALSE; } + + /* Core GLX doesn't explicitly require this, but GLX_ARB_create_context + * does (see glx/createcontext.c), and it's assumed by our + * implementation anyway, so let's be consistent about it. + */ + if (shareglxc->pGlxScreen != pGlxScreen) { + client->errorValue = shareglxc->pGlxScreen->pScreen->myNum; + return BadMatch; + } } /*