apply upstream fix for fc31 blocker

This commit is contained in:
toppk 2019-09-28 10:22:22 -04:00
parent 8fd4a40769
commit c021496c15
No known key found for this signature in database
GPG Key ID: 6C771538FA770FB6
2 changed files with 51 additions and 1 deletions

46
806.patch Normal file
View File

@ -0,0 +1,46 @@
diff --git a/src/core/keybindings.c b/src/core/keybindings.c
index a5a60e8cde30e395968e7d511d599c5a1e56e731..b86272541bd21782b14b63ea10df783f98388d93 100644
--- a/src/core/keybindings.c
+++ b/src/core/keybindings.c
@@ -1933,6 +1933,12 @@ invoke_handler (MetaDisplay *display,
NULL);
}
+static gboolean
+meta_key_binding_has_handler_func (MetaKeyBinding *binding)
+{
+ return (!!binding->handler->func || !!binding->handler->default_func);
+}
+
static gboolean
process_event (MetaDisplay *display,
MetaWindow *window,
@@ -1955,6 +1961,12 @@ process_event (MetaDisplay *display,
(!window && binding->flags & META_KEY_BINDING_PER_WINDOW))
goto not_found;
+ if (binding->handler == NULL)
+ meta_bug ("Binding %s has no handler\n", binding->name);
+
+ if (!meta_key_binding_has_handler_func (binding))
+ goto not_found;
+
if (display->focus_window &&
!(binding->handler->flags & META_KEY_BINDING_NON_MASKABLE))
{
@@ -1980,12 +1992,9 @@ process_event (MetaDisplay *display,
return TRUE;
}
- if (binding->handler == NULL)
- meta_bug ("Binding %s has no handler\n", binding->name);
- else
- meta_topic (META_DEBUG_KEYBINDINGS,
- "Running handler for %s\n",
- binding->name);
+ meta_topic (META_DEBUG_KEYBINDINGS,
+ "Running handler for %s\n",
+ binding->name);
/* Global keybindings count as a let-the-terminal-lose-focus
* due to new window mapping until the user starts

View File

@ -8,7 +8,7 @@
Name: mutter
Version: 3.34.0
Release: 4%{?dist}
Release: 5%{?dist}
Summary: Window and compositing manager based on Clutter
License: GPLv2+
@ -24,6 +24,7 @@ Patch1: 792.patch
Patch2: clutter-timeline-Use-a-function-to-cancel-the-delay-timeo.patch
Patch3: clutter-timeline-Don-t-emit-paused-signal-on-delayed-time.patch
Patch4: clutter-actor-Cancel-delayed-timelines-on-removal.patch
Patch5: 806.patch
BuildRequires: chrpath
@ -169,6 +170,9 @@ desktop-file-validate %{buildroot}/%{_datadir}/applications/%{name}.desktop
%{_datadir}/mutter-%{mutter_api_version}/tests
%changelog
* Sat Sep 28 2019 Kenneth Topp <toppk@bllue.org> - 3.34.0-5
- Backport fix for dual special modifier keys bug (#1754867)
* Fri Sep 27 2019 Kenneth Topp <toppk@bllue.org> - 3.34.0-4
- Backport a patch to prevent crash during animations
- See upstream issue https://gitlab.gnome.org/GNOME/mutter/issues/815