summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
authorBrian <[email protected]>2007-01-10 08:37:59 -0700
committerBrian <[email protected]>2007-01-10 08:37:59 -0700
commit29bff4e12defa0037167ceb0940be632cc87b578 (patch)
tree406816c2cdd9ddadf2eac783715371e0c22cce18 /src/mesa
parent88f721231248854e441ccdaeabe1c471e64ddc0a (diff)
simplify _mesa_add_state_reference()
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/shader/prog_parameter.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/src/mesa/shader/prog_parameter.c b/src/mesa/shader/prog_parameter.c
index 900fb7e1a5c..fbc38398992 100644
--- a/src/mesa/shader/prog_parameter.c
+++ b/src/mesa/shader/prog_parameter.c
@@ -364,16 +364,8 @@ _mesa_add_state_reference(struct gl_program_parameter_list *paramList,
name = _mesa_program_state_string(stateTokens);
index = _mesa_add_parameter(paramList, PROGRAM_STATE_VAR, name,
- size, NULL, NULL);
-
- if (index >= 0) {
- GLuint i;
- for (i = 0; i < STATE_LENGTH; i++) {
- paramList->Parameters[index].StateIndexes[i]
- = (gl_state_index) stateTokens[i];
- }
- paramList->StateFlags |= _mesa_program_state_flags(stateTokens);
- }
+ size, NULL, (gl_state_index *) stateTokens);
+ paramList->StateFlags |= _mesa_program_state_flags(stateTokens);
/* free name string here since we duplicated it in add_parameter() */
_mesa_free((void *) name);