diff --git a/src/virgl_egl_context.c b/src/virgl_egl_context.c index 65c197c..8f56452 100644 --- a/src/virgl_egl_context.c +++ b/src/virgl_egl_context.c @@ -144,6 +144,8 @@ struct virgl_egl *virgl_egl_init(void) return NULL; d->fd = egl_rendernode_open(); + if (d->fd == -1) + goto fail; d->gbm_dev = gbm_create_device(d->fd); if (!d->gbm_dev) goto fail;