summaryrefslogtreecommitdiffstats
path: root/src/glx/dri3_glx.c
diff options
context:
space:
mode:
authorAdam Jackson <[email protected]>2017-11-07 11:36:52 -0500
committerAdam Jackson <[email protected]>2017-11-09 09:35:22 -0500
commit3f66d54a2a59b6f295671ea03aa9f83ce1aee34a (patch)
tree26d7dab3e5d08d53ea44f82600f0e336e2eee15a /src/glx/dri3_glx.c
parent74b701d84cd33b83c96525e70487091a05bb6ad6 (diff)
glx: Prepare the DRI backends for GLX_EXT_no_config_context
This should be safe as these backends already support the EGL version of this extension. DRI1 is not affected because it does not support GLX_ARB_create_context anyway. DRI-Windows is not prepared to implement this as there's no equivalent WGL extension, and wglCreateContextAttribs seems to really want the HDC's pixel format to be set. Signed-off-by: Adam Jackson <[email protected]> Reviewed-by: Eric Anholt <[email protected]>
Diffstat (limited to 'src/glx/dri3_glx.c')
-rw-r--r--src/glx/dri3_glx.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/glx/dri3_glx.c b/src/glx/dri3_glx.c
index d613073994c..fa048f990a9 100644
--- a/src/glx/dri3_glx.c
+++ b/src/glx/dri3_glx.c
@@ -263,7 +263,7 @@ dri3_create_context_attribs(struct glx_screen *base,
goto error_exit;
}
- if (!glx_context_init(&pcp->base, &psc->base, &config->base))
+ if (!glx_context_init(&pcp->base, &psc->base, config_base))
goto error_exit;
ctx_attribs[num_ctx_attribs++] = __DRI_CTX_ATTRIB_MAJOR_VERSION;
@@ -297,7 +297,8 @@ dri3_create_context_attribs(struct glx_screen *base,
pcp->driContext =
(*psc->image_driver->createContextAttribs) (psc->driScreen,
api,
- config->driConfig,
+ config ? config->driConfig
+ : NULL,
shared,
num_ctx_attribs / 2,
ctx_attribs,