From bef423bee62f7b74858f1b7f74be21405ca75eef Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Wed, 26 Jun 2013 15:22:13 -0700 Subject: dri: Choose a decent global driNConfigOptions. Previously, we were asserting that each driver specified an NConfigOptions exactly equal to the number of options they supplied, leading to frequent bugs when people would forget to adjust the value when adjusting driver options. Instead, just overallocate the table by a bit and leave sanity checking to the assert in findOption(). Reviewed-by: Kenneth Graunke --- src/mesa/drivers/dri/i965/intel_screen.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'src/mesa/drivers/dri/i965/intel_screen.c') diff --git a/src/mesa/drivers/dri/i965/intel_screen.c b/src/mesa/drivers/dri/i965/intel_screen.c index 4ee86026574..9b3c31a5e71 100644 --- a/src/mesa/drivers/dri/i965/intel_screen.c +++ b/src/mesa/drivers/dri/i965/intel_screen.c @@ -77,8 +77,6 @@ PUBLIC const char __driConfigOptions[] = DRI_CONF_SECTION_END DRI_CONF_END; -const GLuint __driNConfigOptions = 12; - #include "intel_batchbuffer.h" #include "intel_buffers.h" #include "intel_bufmgr.h" @@ -1259,8 +1257,7 @@ __DRIconfig **intelInitScreen2(__DRIscreen *psp) return false; } /* parse information in __driConfigOptions */ - driParseOptionInfo(&intelScreen->optionCache, - __driConfigOptions, __driNConfigOptions); + driParseOptionInfo(&intelScreen->optionCache, __driConfigOptions); intelScreen->driScrnPriv = psp; psp->driverPrivate = (void *) intelScreen; -- cgit v1.2.3