Module: Mesa Branch: master Commit: f37f1a72095653d4806280e5ef74373781c55184 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=f37f1a72095653d4806280e5ef74373781c55184
Author: Brian Paul <bri...@vmware.com> Date: Thu Jul 26 15:55:26 2012 -0600 svga: initialize svga_compile_key to zeros to be safe --- src/gallium/drivers/svga/svga_tgsi.c | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/src/gallium/drivers/svga/svga_tgsi.c b/src/gallium/drivers/svga/svga_tgsi.c index f4ddefb..8bea7f8 100644 --- a/src/gallium/drivers/svga/svga_tgsi.c +++ b/src/gallium/drivers/svga/svga_tgsi.c @@ -348,6 +348,8 @@ svga_translate_fragment_program( const struct svga_fragment_shader *fs, { struct svga_compile_key key; + memset(&key, 0, sizeof(key)); + memcpy(&key.fkey, fkey, sizeof *fkey); memcpy(key.generic_remap_table, fs->generic_remap_table, @@ -364,6 +366,8 @@ svga_translate_vertex_program( const struct svga_vertex_shader *vs, { struct svga_compile_key key; + memset(&key, 0, sizeof(key)); + memcpy(&key.vkey, vkey, sizeof *vkey); /* Note: we could alternately store the remap table in the vkey but _______________________________________________ mesa-commit mailing list mesa-commit@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-commit