[965] Initialize region surface key structure padding.
authorEric Anholt <eric@anholt.net>
Thu, 20 Mar 2008 00:53:21 +0000 (17:53 -0700)
committerEric Anholt <eric@anholt.net>
Thu, 20 Mar 2008 00:54:06 +0000 (17:54 -0700)
Fixes valgrind warnings, and potential performance loss from cache misses.

src/mesa/drivers/dri/i965/brw_wm_surface_state.c

index 86566df388c64f1c62a0a5d49e95102094e0fed8..c5c944f781f5125988ca4cb975657820805bd1f6 100644 (file)
@@ -257,6 +257,8 @@ brw_update_region_surface(struct brw_context *brw, struct intel_region *region,
       GLboolean tiled, color_blend;
    } key;
 
+   memset(&key, 0, sizeof(key));
+
    if (region != NULL) {
       region_bo = region->buffer;