aboutsummaryrefslogtreecommitdiffstats
path: root/src/egl/drivers/dri2
diff options
context:
space:
mode:
authorEmil Velikov <[email protected]>2017-06-29 00:24:27 +0100
committerEmil Velikov <[email protected]>2017-07-12 15:43:15 +0100
commita2ae8e6076cfdb4b3100d5d7c444c2f8ed68f5f5 (patch)
tree3dd30e450c01b6234c737e97b0c41180305f9b73 /src/egl/drivers/dri2
parent4d8191fd000071328b97bde5fc31ab1c39238d27 (diff)
egl: don't set modifier if no modifiers are available
If no modifiers are available, the variable will never be used. Thus there's no point in initialising it. Cc: Varad Gautam <[email protected]> Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Eric Engestrom <[email protected]>
Diffstat (limited to 'src/egl/drivers/dri2')
-rw-r--r--src/egl/drivers/dri2/egl_dri2.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/src/egl/drivers/dri2/egl_dri2.c b/src/egl/drivers/dri2/egl_dri2.c
index c96f0e0d21b..a641d774523 100644
--- a/src/egl/drivers/dri2/egl_dri2.c
+++ b/src/egl/drivers/dri2/egl_dri2.c
@@ -2238,8 +2238,6 @@ dri2_create_image_dma_buf(_EGLDisplay *disp, _EGLContext *ctx,
modifier = (uint64_t) attrs.DMABufPlaneModifiersHi[0].Value << 32;
modifier |= (uint64_t) (attrs.DMABufPlaneModifiersLo[0].Value & 0xffffffff);
has_modifier = true;
- } else {
- modifier = DRM_FORMAT_MOD_INVALID;
}
if (has_modifier) {