Merge branch 'fix-ephy-crash' into 'main'

subsurface: Avoid a crash

Closes #6891

See merge request GNOME/gtk!7521
This commit is contained in:
Matthias Clasen 2024-07-29 17:39:05 +00:00
commit 9fd6d431e3

View File

@ -29,11 +29,14 @@ gdk_subsurface_init (GdkSubsurface *self)
{
}
static void remove_subsurface (GdkSubsurface *subsurface);
static void
gdk_subsurface_finalize (GObject *object)
{
GdkSubsurface *subsurface = GDK_SUBSURFACE (object);
remove_subsurface (subsurface);
g_ptr_array_remove (subsurface->parent->subsurfaces, subsurface);
g_clear_object (&subsurface->parent);