diff options
author | Mathias Fröhlich <[email protected]> | 2012-01-28 18:55:08 +0100 |
---|---|---|
committer | Mathias Fröhlich <[email protected]> | 2012-01-29 00:15:48 +0100 |
commit | 1d01429c6a1ae679d0cc0cb61db1948fca5ced4c (patch) | |
tree | 7c3b5bc1e6d0fa74368f656fd5775052035eca83 /src/mesa | |
parent | 743432039ccd4c4af03aa4ef274a7922f871bc38 (diff) |
state_stracker: Fix access to uninitialized memory.
Fix an access to uninitialized memory pointed out by valgrind in
glsl_to_tgsi_visitor::simplify_cmp(void).
Note: This is a candidate for the 8.0 branch.
Signed-off-by: Mathias Fröhlich <[email protected]>
Diffstat (limited to 'src/mesa')
-rw-r--r-- | src/mesa/state_tracker/st_glsl_to_tgsi.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp index 188e8d9d5c9..ab05896ce45 100644 --- a/src/mesa/state_tracker/st_glsl_to_tgsi.cpp +++ b/src/mesa/state_tracker/st_glsl_to_tgsi.cpp @@ -2978,7 +2978,7 @@ glsl_to_tgsi_visitor::simplify_cmp(void) if (!tempWrites) { return; } - memset(tempWrites, 0, sizeof(tempWrites)); + memset(tempWrites, 0, sizeof(unsigned) * MAX_TEMPS); memset(outputWrites, 0, sizeof(outputWrites)); foreach_iter(exec_list_iterator, iter, this->instructions) { |