summaryrefslogtreecommitdiffstats
path: root/src/mesa/glapi
diff options
context:
space:
mode:
authorGeorge Sapountzis <[email protected]>2010-03-08 01:58:59 +0200
committerGeorge Sapountzis <[email protected]>2010-03-10 18:44:46 +0200
commitc4b630efdb882f824e9099b9cb2e07d8db2e3549 (patch)
treea5b6a665d7eabec9a8190d751e634b76f7c09f08 /src/mesa/glapi
parent3833a76eef6b45b82c102a49055602632f960a99 (diff)
glapi: minor cosmetic for _glapi_add_dispatch
Diffstat (limited to 'src/mesa/glapi')
-rw-r--r--src/mesa/glapi/glapi_getproc.c21
1 files 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;
}