From 73e9aa9e3f73d69ce4f0b68e74702d67842a230c Mon Sep 17 00:00:00 2001 From: Ian Romanick Date: Wed, 20 Nov 2013 09:09:50 -0800 Subject: [PATCH] dri: Allow __DRI_CTX_FLAG_ROBUST_BUFFER_ACCESS in driCreateContextAttribs Signed-off-by: Ian Romanick Reported-by: Zhenyu Wang Reviewed-by: Matt Turner Reviewed-by: Kenneth Graunke Cc: "10.0" --- src/mesa/drivers/dri/common/dri_util.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/mesa/drivers/dri/common/dri_util.c b/src/mesa/drivers/dri/common/dri_util.c index 44e47f94f82..0bce77ea9c7 100644 --- a/src/mesa/drivers/dri/common/dri_util.c +++ b/src/mesa/drivers/dri/common/dri_util.c @@ -407,8 +407,10 @@ driCreateContextAttribs(__DRIscreen *screen, int api, mesa_api = API_OPENGL_CORE; } - if ((flags & ~(__DRI_CTX_FLAG_DEBUG | __DRI_CTX_FLAG_FORWARD_COMPATIBLE)) - != 0) { + const uint32_t allowed_flags = (__DRI_CTX_FLAG_DEBUG + | __DRI_CTX_FLAG_FORWARD_COMPATIBLE + | __DRI_CTX_FLAG_ROBUST_BUFFER_ACCESS); + if (flags & ~allowed_flags) { *error = __DRI_CTX_ERROR_UNKNOWN_FLAG; return NULL; } -- 2.30.2