projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
aa43176
)
st/mesa: Silence uninitialized variable warning.
author
Vinson Lee
<vlee@vmware.com>
Thu, 28 Oct 2010 13:08:19 +0000
(06:08 -0700)
committer
Vinson Lee
<vlee@vmware.com>
Thu, 28 Oct 2010 13:08:19 +0000
(06:08 -0700)
Fixes this GCC warning.
state_tracker/st_program.c: In function 'st_print_shaders':
state_tracker/st_program.c:735: warning: 'sh' may be used uninitialized in this function
src/mesa/state_tracker/st_program.c
patch
|
blob
|
history
diff --git
a/src/mesa/state_tracker/st_program.c
b/src/mesa/state_tracker/st_program.c
index 6a5d741b61b491e7cb2ec0d650236797b30967b0..76799287fe12dff9c69de2254f87eae223596f74 100644
(file)
--- a/
src/mesa/state_tracker/st_program.c
+++ b/
src/mesa/state_tracker/st_program.c
@@
-744,6
+744,10
@@
st_print_shaders(struct gl_context *ctx)
case GL_FRAGMENT_SHADER:
sh = (i != 2) ? NULL : shProg[j]->Shaders[i];
break;
+ default:
+ assert(0);
+ sh = NULL;
+ break;
}
if (sh != NULL) {