Created attachment 1440280 [details]
Description of problem:
1) gnome-shell is "crashing" when a modal Java popup is programmatically popped down if the user is in the process of moving/resizing the parent window.
Version-Release number of selected component (if applicable):
recreateable using the attached test code.
Steps to Reproduce:
1) Start the SwingTest application
2) Click the "Popup" button.
3) Observe the new modal popup entitled "Modal" pops up.
4) Observe the stdout emits "In 3...\nIn 2...\nIn 1...\nBOOM!?".
5) Observe the modal popup comes down
6) Repeat steps 2-4, however during step 4, before "BOOM!?" is output, begin moving the parent window "Test" (grab title bar and start moving the window around), make sure the window is still being moved when "BOOM!?" is output. (Note: being in the process of resizing also seems to work, there may be other actions that will cause the issue).
7) Observe that when the modal popup comes down the window manager "crashes" (in our environment, sometimes it restores itself others it kicks to login screen).
mutter will crash on an assertion
Where are you experiencing the behavior? What environment?
Within attached test application (which is a distillation of our production code). Code was compiled and executed with Java jdk1.8.0_112 (and jdk1.6.0_15 and other Java versions, under no version was the proper behavior encountered, though different bad behavior can be seen in the resize tests from 1.6 to 1.8).
When does the behavior occur? Frequently? Repeatedly? At certain times?
What information can you provide around timeframes and the business impact?
Our organization is migrating from RHEL 5 to RHEL 7 and this is impacting the deployment of our applications to the new hardware/software.
diff -up mutter-3.26.2/src/core/window.c.focus-unmanage mutter-3.26.2/src/core/window.c
--- mutter-3.26.2/src/core/window.c.focus-unmanage 2018-05-22 10:32:59.495260835 -0400
+++ mutter-3.26.2/src/core/window.c 2018-05-22 10:34:03.824925352 -0400
@@ -1475,7 +1475,6 @@ meta_window_unmanage (MetaWindow *windo
- g_assert (window->display->focus_window != window);
removing this assertion seems to resolve the problem. The assertion was introduced in
But it's not in the original metacity code.
(In reply to Alan Matsuoka from comment #3)
> removing this assertion seems to resolve the problem.
No, that's a work-around and not a fix - the issue is that for some reason we fail to move the focus to a different window when the focus window is destroyed.
I've been able to reproduce the problem and proposed a fix upstream:
(In reply to Florian Müllner from comment #6)
> (In reply to Alan Matsuoka from comment #3)
> > removing this assertion seems to resolve the problem.
> No, that's a work-around and not a fix - the issue is that for some reason
> we fail to move the focus to a different window when the focus window is
> I've been able to reproduce the problem and proposed a fix upstream:
I can see the proposed change was merged is there something else that need to be done?
(In reply to Tomas Pelka from comment #7)
> (In reply to Florian Müllner from comment #6)
> > I've been able to reproduce the problem and proposed a fix upstream:
> > https://gitlab.gnome.org/GNOME/mutter/merge_requests/118
> I can see the proposed change was merged
No, it hasn't been merge yet. But the feedback was generally positive, so this should be good to ship downstream.
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.