From 3e0617cf3bbcda64cf1868f6a50d4303a8091caa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alberts=20Muktup=C4=81vels?= Date: Tue, 17 Oct 2017 15:45:15 +0300 Subject: window: don't manage InputOnly windows --- src/core/window.c | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/core/window.c b/src/core/window.c index 3c5b2c2b..277613f2 100644 --- a/src/core/window.c +++ b/src/core/window.c @@ -290,6 +290,8 @@ meta_window_new (MetaDisplay *display, gulong event_mask; MetaMoveResizeFlags flags; + meta_verbose ("Attempting to manage 0x%lx\n", xwindow); + meta_error_trap_push (display); /* Push a trap over all of window * creation, to reduce XSync() calls */ @@ -301,9 +303,19 @@ meta_window_new (MetaDisplay *display, return NULL; } - g_assert (display->screen->xroot == attrs.root); + if (attrs.root != display->screen->xroot) + { + meta_verbose ("Not on our screen\n"); + meta_error_trap_pop (display); + return NULL; + } - meta_verbose ("Attempting to manage 0x%lx\n", xwindow); + if (attrs.class == InputOnly) + { + meta_verbose ("Not managing InputOnly windows\n"); + meta_error_trap_pop (display); + return NULL; + } if (is_our_xwindow (display, xwindow, &attrs)) { -- cgit v1.2.1