From: Brian Paul Date: Tue, 27 Jul 2010 02:49:35 +0000 (-0600) Subject: cell: fix segfault when freeing samplers X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=0315c00f5897eb443254323be2b7b5ca213fbef2;p=mesa.git cell: fix segfault when freeing samplers --- diff --git a/src/gallium/drivers/cell/ppu/cell_pipe_state.c b/src/gallium/drivers/cell/ppu/cell_pipe_state.c index 03f84d295b5..223adda48f0 100644 --- a/src/gallium/drivers/cell/ppu/cell_pipe_state.c +++ b/src/gallium/drivers/cell/ppu/cell_pipe_state.c @@ -281,7 +281,7 @@ cell_set_fragment_sampler_views(struct pipe_context *pipe, struct pipe_resource *new_tex = new_view ? new_view->texture : NULL; pipe_sampler_view_reference(&cell->fragment_sampler_views[i], - views[i]); + new_view); pipe_resource_reference((struct pipe_resource **) &cell->texture[i], (struct pipe_resource *) new_tex);