[Mesa-dev] [PATCH v4 4/9] egl: add a missed initialization of buffer age.

Gwan-gyeong Mun elongbug at gmail.com
Thu Nov 2 22:10:49 UTC 2017


It add an initialization of buffer age on dri2_surface_set_back_buffer().

Fixes from Emil's review
 - Split out separated patch for adding of missed initialization of buffer
   age. [1]

[1] https://lists.freedesktop.org/archives/mesa-dev/2017-October/173129.html

Signed-off-by: Mun Gwan-gyeong <elongbug at gmail.com>
---
 src/egl/drivers/dri2/egl_dri2.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/egl/drivers/dri2/egl_dri2.c b/src/egl/drivers/dri2/egl_dri2.c
index 2063d1ca56..edb692c7e5 100644
--- a/src/egl/drivers/dri2/egl_dri2.c
+++ b/src/egl/drivers/dri2/egl_dri2.c
@@ -1104,6 +1104,7 @@ dri2_surface_set_back_buffer(_EGLSurface *surf, void *buffer)
    for (int i = 0; i < ARRAY_SIZE(dri2_surf->color_buffers); i++) {
       if (!dri2_surf->color_buffers[i].native_buffer) {
          dri2_surf->color_buffers[i].native_buffer = buffer;
+         dri2_surf->color_buffers[i].age = 0;
       }
       if (dri2_surf->color_buffers[i].native_buffer == buffer) {
          dri2_surf->back = &dri2_surf->color_buffers[i];
-- 
2.15.0



More information about the mesa-dev mailing list