r300g: fix a surface leak when flushing ZMASK
authorMarek Olšák <maraeo@gmail.com>
Sat, 8 Jan 2011 08:42:17 +0000 (09:42 +0100)
committerMarek Olšák <maraeo@gmail.com>
Sat, 8 Jan 2011 08:42:17 +0000 (09:42 +0100)
src/gallium/drivers/r300/r300_blit.c

index 6e886433bc55e8428fd154f7ceb251251bd25adc..017db48485b944bd3c33b06a4bfa92b1703162ac 100644 (file)
@@ -326,6 +326,7 @@ void r300_flush_depth_stencil(struct pipe_context *pipe,
     r300->z_decomp_rd = FALSE;
 
     tex->zmask_in_use[level] = FALSE;
+    pipe_surface_reference(&dstsurf, NULL);
 }
 
 /* Copy a block of pixels from one surface to another using HW. */