[PATCH weston] gl-renderer: allow EGL_NATIVE_VISUAL_ID to be 0 in configs

Manuel Bachmann manuel.bachmann at iot.bzh
Wed Nov 4 05:57:11 PST 2015


Accept 0 as a valid value for the EGL_NATIVE_VISUAL_ID
attribute in EGL configurations, just as we did before
commit e76f185.

(fixes running Weston with DRM backend and gl-renderer
on Lenovo ThinkPad with i915 driver)

Signed-off-by: Manuel Bachmann <manuel.bachmann at iot.bzh>
---
 src/gl-renderer.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/gl-renderer.c b/src/gl-renderer.c
index d7231f4..85c69f3 100644
--- a/src/gl-renderer.c
+++ b/src/gl-renderer.c
@@ -2194,7 +2194,7 @@ match_config_to_visual(EGLDisplay egl_display,
 				&id))
 			continue;
 
-		if (id == visual_id)
+		if (id == 0 || id == visual_id)
 			return i;
 	}
 
-- 
1.8.3.1



More information about the wayland-devel mailing list