backend-headless: Fix pointer vs. int confusion with EGL

EGL's native display type is not particularly well defined; in
gl-renderer we get around this by always treating it as a void *, since
for all the platforms we care about it's a pointer - gbm_device,
wl_display, or Display *.

The surfaceless platform doesn't care what the native display is (since
it doesn't have one by definition), so just use NULL instead of what may
be either NULL or 0 depending on environmental factors.

Signed-off-by: Daniel Stone <daniels@collabora.com>
dev
Daniel Stone 3 years ago
parent eeaaf6b9b0
commit fa6ae44719
  1. 2
      libweston/backend-headless/headless.c

@ -399,7 +399,7 @@ headless_gl_renderer_init(struct headless_backend *b)
{
const struct gl_renderer_display_options options = {
.egl_platform = EGL_PLATFORM_SURFACELESS_MESA,
.egl_native_display = EGL_DEFAULT_DISPLAY,
.egl_native_display = NULL,
.egl_surface_type = EGL_PBUFFER_BIT,
.drm_formats = headless_formats,
.drm_formats_count = ARRAY_LENGTH(headless_formats),

Loading…
Cancel
Save