egl/wayland: Cleanup private display connection when init fails
authorJonas Ådahl <jadahl@gmail.com>
Fri, 13 Jan 2017 15:05:09 +0000 (23:05 +0800)
committerEmil Velikov <emil.l.velikov@gmail.com>
Fri, 13 Jan 2017 15:50:04 +0000 (15:50 +0000)
commit361796651c5abb21ff429466c061119dce8f33d5
treeb215b57df5f424c0ad5f80e0f102aab542891e4a
parentcba808695148cda65be5c8df2d8be76e406369b1
egl/wayland: Cleanup private display connection when init fails

When failing to initializing the Wayland EGL driver, don't leak the
display server connection if it was us who created it.

Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
Cc: mesa-stable@lists.freedesktop.org
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Daniel Stone <daniels@collabora.com>
src/egl/drivers/dri2/platform_wayland.c