i965g: initialize surface refcount
authorKeith Whitwell <keithw@vmware.com>
Wed, 4 Nov 2009 19:03:06 +0000 (19:03 +0000)
committerKeith Whitwell <keithw@vmware.com>
Wed, 4 Nov 2009 19:03:06 +0000 (19:03 +0000)
src/gallium/drivers/i965/brw_screen_surface.c

index b4ad912..04a6fc7 100644 (file)
@@ -130,6 +130,8 @@ static struct brw_surface *create_in_place_view( struct brw_screen *brw_screen,
    if (surface == NULL)
       return NULL;
 
+   pipe_reference_init(&surface->base.reference, 1);
+
    /* XXX: ignoring render-to-slice-of-3d-texture
     */
    assert(id.bits.zslice == 0);