From c4b630efdb882f824e9099b9cb2e07d8db2e3549 Mon Sep 17 00:00:00 2001 From: George Sapountzis Date: Mon, 8 Mar 2010 01:58:59 +0200 Subject: [PATCH] glapi: minor cosmetic for _glapi_add_dispatch --- src/mesa/glapi/glapi_getproc.c | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/src/mesa/glapi/glapi_getproc.c b/src/mesa/glapi/glapi_getproc.c index 95974fe3a0f..1badff81ea7 100644 --- a/src/mesa/glapi/glapi_getproc.c +++ b/src/mesa/glapi/glapi_getproc.c @@ -472,20 +472,21 @@ _glapi_add_dispatch( const char * const * function_names, } for ( i = 0 ; function_names[i] != NULL ; i++ ) { - if (! is_static[i] ) { + if (is_static[i]) { + continue; + } + + if (entry[i] == NULL) { + entry[i] = add_function_name( function_names[i] ); if (entry[i] == NULL) { - entry[i] = add_function_name( function_names[i] ); - if (entry[i] == NULL) { - /* FIXME: Possible memory leak here. - */ - return -1; - } + /* FIXME: Possible memory leak here. */ + return -1; } - - set_entry_info( entry[i], real_sig, offset ); } + + set_entry_info( entry[i], real_sig, offset ); } - + return offset; } -- 2.30.2