[gnome-build-meta/mcatanzaro/crashy-crashy] Fix WebKit crashes




commit 58c00da20fcdbf51a7f69f461decf6444de44d21
Author: Michael Catanzaro <mcatanzaro redhat com>
Date:   Thu May 20 08:34:05 2021 -0500

    Fix WebKit crashes
    
    This fixes https://bugs.webkit.org/show_bug.cgi?id=225795

 elements/sdk/webkitgtk.bst        |  2 ++
 files/webkitgtk/fix-crashes.patch | 15 +++++++++++++++
 2 files changed, 17 insertions(+)
---
diff --git a/elements/sdk/webkitgtk.bst b/elements/sdk/webkitgtk.bst
index cbacc5bb..da7f91d5 100644
--- a/elements/sdk/webkitgtk.bst
+++ b/elements/sdk/webkitgtk.bst
@@ -9,6 +9,8 @@ sources:
   path: files/webkitgtk/toolchain.arm
 - kind: patch
   path: files/webkitgtk/fix-build.patch
+- kind: patch
+  path: files/webkitgtk/fix-crashes.patch
 
 build-depends:
 - sdk-deps/bubblewrap.bst
diff --git a/files/webkitgtk/fix-crashes.patch b/files/webkitgtk/fix-crashes.patch
new file mode 100644
index 00000000..bd532343
--- /dev/null
+++ b/files/webkitgtk/fix-crashes.patch
@@ -0,0 +1,15 @@
+--- /Source/WebCore/editing/FrameSelection.cpp (revision 277599)
++++ /Source/WebCore/editing/FrameSelection.cpp (revision 277600)
+@@ -364,5 +364,5 @@
+         }
+ 
+-        if (!m_document) {
++        if (!m_document || (!m_document->frame() && !newSelection.document())) {
+             m_selection = newSelection;
+             updateAssociatedLiveRange();
+@@ -377,4 +377,5 @@
+             return false;
+         }
++        ASSERT(m_document->frame());
+ 
+         if (closeTyping)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]