From 2be9f795bc15012dc912f595003e01bb6aa66f54 Mon Sep 17 00:00:00 2001 From: Olivier Fourdan Date: Wed, 23 Jun 2021 11:35:17 +0200 Subject: [PATCH] xwayland/eglstream: Keep pending stream if the pixmap didn't change MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit If the pixmap does not actually change in set_window_pixmap(), there is no need to invalidate the pending stream, if there's one. Signed-off-by: Olivier Fourdan Suggested-by: Michel Dänzer Reviewed-by: Michel Dänzer --- hw/xwayland/xwayland-glamor-eglstream.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/xwayland/xwayland-glamor-eglstream.c b/hw/xwayland/xwayland-glamor-eglstream.c index 032f8a600..e06f30214 100644 --- a/hw/xwayland/xwayland-glamor-eglstream.c +++ b/hw/xwayland/xwayland-glamor-eglstream.c @@ -382,7 +382,7 @@ xwl_eglstream_set_window_pixmap(WindowPtr window, PixmapPtr pixmap) * attached, so the stream would be useless. */ old_pixmap = (*screen->GetWindowPixmap) (window); - if (old_pixmap) + if (old_pixmap && old_pixmap != pixmap) xwl_eglstream_maybe_set_pending_stream_invalid(old_pixmap); xwl_screen->screen->SetWindowPixmap = xwl_eglstream->SetWindowPixmap;