util: Silence gcc unitialized member warning
authorJosé Fonseca <jfonseca@vmware.com>
Sat, 12 Mar 2011 20:39:17 +0000 (20:39 +0000)
committerJosé Fonseca <jfonseca@vmware.com>
Sun, 13 Mar 2011 18:56:19 +0000 (18:56 +0000)
src/gallium/auxiliary/util/u_vbuf_mgr.c

index 51bb4b858504f570ce82e2b672fe5b7f69887353..521ac07747cee92d07e6512aa2d0f56d4d3a25d6 100644 (file)
@@ -170,6 +170,7 @@ static void u_vbuf_translate_begin(struct u_vbuf_mgr_priv *mgr,
 
    /* Initialize the translate key, i.e. the recipe how vertices should be
      * translated. */
+   memset(&key, 0, sizeof key);
    for (i = 0; i < mgr->ve->count; i++) {
       struct pipe_vertex_buffer *vb =
             &mgr->b.vertex_buffer[mgr->ve->ve[i].vertex_buffer_index];