From a3f82876f4471b88158074766c6115e15642d734 Mon Sep 17 00:00:00 2001 From: Emil Velikov Date: Tue, 24 Oct 2017 15:57:08 +0100 Subject: [PATCH] mesa: reuse set_extension() for _mesa_extension_override_disables We already use it for _mesa_extension_override_enables. Improve consistency and use it for both extension lists. Signed-off-by: Emil Velikov Reviewed-by: Brian Paul --- src/mesa/main/extensions.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/mesa/main/extensions.c b/src/mesa/main/extensions.c index 351ed1c4dd4..2468e19bf99 100644 --- a/src/mesa/main/extensions.c +++ b/src/mesa/main/extensions.c @@ -287,12 +287,11 @@ _mesa_one_time_init_extension_overrides(void) i = name_to_index(ext); offset = set_extension(&_mesa_extension_override_enables, i, enable); - if (offset != 0 && (offset != o(dummy_true) || enable != GL_FALSE)) { - ((GLboolean *) &_mesa_extension_override_disables)[offset] = !enable; + offset = set_extension(&_mesa_extension_override_disables, i, !enable); + if (offset != 0) recognized = true; - } else { + else recognized = false; - } if (!recognized && enable) { strcat(extra_extensions, ext); -- 2.30.2