diff --git a/hw/xwayland/xwayland-glamor-eglstream.c b/hw/xwayland/xwayland-glamor-eglstream.c index 399a691d3..ce066cd9e 100644 --- a/hw/xwayland/xwayland-glamor-eglstream.c +++ b/hw/xwayland/xwayland-glamor-eglstream.c @@ -670,7 +670,14 @@ xwl_glamor_eglstream_allow_commits(struct xwl_window *xwl_window) return FALSE; } else { - return TRUE; + if (xwl_pixmap->surface != EGL_NO_SURFACE) + return TRUE; + + /* The pending stream got removed, we have a xwl_pixmap and + * yet we do not have a surface. + * So something went wrong with the surface creation, retry. + */ + xwl_eglstream_destroy_pixmap_stream(xwl_pixmap); } }