On 10/14/2015 10:03 AM, Krzysztof A. Sobiecki wrote:
From: Krzysztof Sobiecki <sob...@gmail.com>

pipe_surface_reference have problems with deleted contexts,
so use of pipe_surface_release might be more appropriate.

Fixes Wasteland 2 Director's Cut crash on start.
---
  src/mesa/state_tracker/st_cb_fbo.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/mesa/state_tracker/st_cb_fbo.c 
b/src/mesa/state_tracker/st_cb_fbo.c
index ff703fa..2a2eb09 100644
--- a/src/mesa/state_tracker/st_cb_fbo.c
+++ b/src/mesa/state_tracker/st_cb_fbo.c
@@ -456,7 +456,7 @@ st_update_renderbuffer_surface(struct st_context *st,
        surf_tmpl.u.tex.first_layer = first_layer;
        surf_tmpl.u.tex.last_layer = last_layer;

-      pipe_surface_reference(&strb->surface, NULL);
+      pipe_surface_release(pipe, &strb->surface);

        strb->surface = pipe->create_surface(pipe, resource, &surf_tmpl);
     }


Reviewed-by: Brian Paul <bri...@vmware.com>

Do you need me to commit this for you?

-Brian

_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to