From cd8aa57c8b6a5162dbfa8a774965cdccbf85247e Mon Sep 17 00:00:00 2001 From: Milan Crha Date: Mon, 30 Nov 2020 09:27:46 +0100 Subject: [PATCH] Resolves: #1888558 (Crash on file drag into mail composer with WebKitGTK 2.30) --- evolution-3.36.5-webkitgtk-2.30.patch | 39 +++++++++++++++++++++++++++ evolution.spec | 8 +++++- 2 files changed, 46 insertions(+), 1 deletion(-) create mode 100644 evolution-3.36.5-webkitgtk-2.30.patch diff --git a/evolution-3.36.5-webkitgtk-2.30.patch b/evolution-3.36.5-webkitgtk-2.30.patch new file mode 100644 index 0000000..d9135f9 --- /dev/null +++ b/evolution-3.36.5-webkitgtk-2.30.patch @@ -0,0 +1,39 @@ +diff -up evolution-3.36.5/src/modules/webkit-editor/e-webkit-editor.c.webkitgtk-2.30 evolution-3.36.5/src/modules/webkit-editor/e-webkit-editor.c +--- evolution-3.36.5/src/modules/webkit-editor/e-webkit-editor.c.webkitgtk-2.30 2020-08-07 09:38:49.000000000 +0200 ++++ evolution-3.36.5/src/modules/webkit-editor/e-webkit-editor.c 2020-11-30 09:25:45.562429340 +0100 +@@ -6152,11 +6152,12 @@ webkit_editor_drag_data_received_cb (Gtk + info == E_DND_TARGET_TYPE_UTF8_STRING || info == E_DND_TARGET_TYPE_STRING || + info == E_DND_TARGET_TYPE_TEXT_PLAIN || info == E_DND_TARGET_TYPE_TEXT_PLAIN_UTF8) { + gdk_drag_status (context, gdk_drag_context_get_selected_action(context), time); +- if (!GTK_WIDGET_CLASS (e_webkit_editor_parent_class)->drag_drop (widget, context, x, y, time)) { +- g_warning ("Drop failed in WebKit"); ++ if (!GTK_WIDGET_CLASS (e_webkit_editor_parent_class)->drag_drop || ++ !GTK_WIDGET_CLASS (e_webkit_editor_parent_class)->drag_drop (widget, context, x, y, time)) { + goto process_ourselves; + } else { +- GTK_WIDGET_CLASS (e_webkit_editor_parent_class)->drag_leave(widget, context, time); ++ if (GTK_WIDGET_CLASS (e_webkit_editor_parent_class)->drag_leave) ++ GTK_WIDGET_CLASS (e_webkit_editor_parent_class)->drag_leave (widget, context, time); + g_signal_stop_emission_by_name (widget, "drag-data-received"); + if (!is_move) + webkit_editor_call_simple_extension_function (wk_editor, "DOMLastDropOperationDidCopy"); +@@ -6384,7 +6385,8 @@ webkit_editor_button_press_event (GtkWid + } + + /* Chain up to parent's button_press_event() method. */ +- return GTK_WIDGET_CLASS (e_webkit_editor_parent_class)->button_press_event (widget, event); ++ return GTK_WIDGET_CLASS (e_webkit_editor_parent_class)->button_press_event && ++ GTK_WIDGET_CLASS (e_webkit_editor_parent_class)->button_press_event (widget, event); + } + + static gboolean +@@ -6457,7 +6459,8 @@ webkit_editor_key_press_event (GtkWidget + return FALSE; + + /* Chain up to parent's key_press_event() method. */ +- return GTK_WIDGET_CLASS (e_webkit_editor_parent_class)->key_press_event (widget, event); ++ return GTK_WIDGET_CLASS (e_webkit_editor_parent_class)->key_press_event && ++ GTK_WIDGET_CLASS (e_webkit_editor_parent_class)->key_press_event (widget, event); + } + + static void diff --git a/evolution.spec b/evolution.spec index 03548cf..9ff3246 100644 --- a/evolution.spec +++ b/evolution.spec @@ -41,7 +41,7 @@ Name: evolution Version: 3.36.5 -Release: 1%{?dist} +Release: 2%{?dist} Summary: Mail and calendar client for GNOME License: GPLv2+ and GFDL URL: https://wiki.gnome.org/Apps/Evolution @@ -49,6 +49,8 @@ Source: http://download.gnome.org/sources/%{name}/3.36/%{name}-%{version}.tar.xz Source1: flatpak-evolution-fix-service-names.sh Source2: flatpak-evolution-wrapper.sh.in +Patch01: evolution-3.36.5-webkitgtk-2.30.patch + Obsoletes: anjal <= %{last_anjal_version} Obsoletes: libgal2 <= %{last_libgal2_version} Obsoletes: evolution-NetworkManager < %{last_evo_nm_version} @@ -235,6 +237,7 @@ the functionality of the installed %{name} package. %prep %setup -q -n %{name}-%{version} +%patch01 -p1 -b .webkitgtk-2.30 # Remove the welcome email from Novell for inbox in src/mail/default/*/Inbox; do @@ -560,6 +563,9 @@ grep -v "%{_datadir}/locale" evolution.lang > help.lang %endif %changelog +* Mon Nov 30 2020 Milan Crha - 3.36.5-2 +- Resolves: #1888558 (Crash on file drag into mail composer with WebKitGTK 2.30) + * Fri Aug 07 2020 Milan Crha - 3.36.5-1 - Update to 3.36.5