From 5f49bda5917f4a0a0bc966d83fc49e41ac0ca772 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20M=C3=BCllner?= Date: Wed, 7 Jun 2017 14:12:39 +0200 Subject: [PATCH] window: Include window itself in transient loop check While it doesn't make sense to set a window as transient to itself, our existing check whether making a window transient doesn't cover it, so it's still possible to create an infinite loop. https://bugzilla.gnome.org/show_bug.cgi?id=783502 --- src/core/window.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/window.c b/src/core/window.c index 36ea96f40..a6ec04fce 100644 --- a/src/core/window.c +++ b/src/core/window.c @@ -7508,7 +7508,7 @@ check_transient_for_loop (MetaWindow *window, { while (parent) { - if (parent->transient_for == window) + if (parent == window) return TRUE; parent = parent->transient_for; }