[Mesa-dev] [PATCH] vl/dri3: do full teardown on screen_destroy

Emil Velikov emil.l.velikov at gmail.com
Wed Aug 29 17:14:02 UTC 2018

From: Emil Velikov <emil.velikov at collabora.com>

Earlier commit added support for 'front_buffers', erroneously adding a
return in vl_dri3_screen_destroy. Effectively leaking a lot of state.

Fixes: 8d7ac0a4e4d ("vl/dri3: implement DRI3 BufferFromPixmap")
Cc: Leo Liu <leo.liu at amd.com>
Cc: Christian K├Ânig <christian.koenig at amd.com>
Signed-off-by: Emil Velikov <emil.velikov at collabora.com>
Gents, can you please double-check this. I haven't really looked at the
implementation, although the return seems bogus here.

 src/gallium/auxiliary/vl/vl_winsys_dri3.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/src/gallium/auxiliary/vl/vl_winsys_dri3.c b/src/gallium/auxiliary/vl/vl_winsys_dri3.c
index 8e3c4a0e04d..df2c9c0e50c 100644
--- a/src/gallium/auxiliary/vl/vl_winsys_dri3.c
+++ b/src/gallium/auxiliary/vl/vl_winsys_dri3.c
@@ -712,7 +712,6 @@ vl_dri3_screen_destroy(struct vl_screen *vscreen)
    if (scrn->front_buffer) {
       dri3_free_front_buffer(scrn, scrn->front_buffer);
       scrn->front_buffer = NULL;
-      return;
    for (i = 0; i < BACK_BUFFER_NUM; ++i) {

More information about the mesa-dev mailing list