gallium/radeon: Use flags parameter in radeon_winsys_surface_init
authorMichel Dänzer <michel.daenzer@amd.com>
Wed, 2 Nov 2016 10:48:35 +0000 (19:48 +0900)
committerMichel Dänzer <michel@daenzer.net>
Fri, 4 Nov 2016 07:49:39 +0000 (16:49 +0900)
Fixes valgrind warnings about surf_ws->flags being uninitialized while
starting X.

Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
src/gallium/winsys/radeon/drm/radeon_drm_surface.c

index 7b85973bf442b24a15a4097fc7e2b9ffb805af51..6836a1ba3ad673701a6872edffca1e1449ca8c3a 100644 (file)
@@ -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;