[Mesa-dev] [PATCH 3/4] gallium/radeon: Use flags parameter in radeon_winsys_surface_init

Michel Dänzer michel at daenzer.net
Wed Nov 2 11:11:56 UTC 2016


From: Michel Dänzer <michel.daenzer at amd.com>

Fixes valgrind warnings about surf_ws->flags being uninitialized while
starting X.

Signed-off-by: Michel Dänzer <michel.daenzer at amd.com>
---
 src/gallium/winsys/radeon/drm/radeon_drm_surface.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/gallium/winsys/radeon/drm/radeon_drm_surface.c b/src/gallium/winsys/radeon/drm/radeon_drm_surface.c
index 7b85973..6836a1b 100644
--- a/src/gallium/winsys/radeon/drm/radeon_drm_surface.c
+++ b/src/gallium/winsys/radeon/drm/radeon_drm_surface.c
@@ -228,7 +228,7 @@ static int radeon_winsys_surface_init(struct radeon_winsys *rws,
 
     surf_winsys_to_drm(&surf_drm, tex, flags, bpe, mode, surf_ws);
 
-    if (!(surf_ws->flags & RADEON_SURF_IMPORTED)) {
+    if (!(flags & RADEON_SURF_IMPORTED)) {
        r = radeon_surface_best(ws->surf_man, &surf_drm);
        if (r)
           return r;
-- 
2.10.2



More information about the mesa-dev mailing list