mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-12-28 22:41:43 +00:00
inspector: Don't leak recordings
g_list_model_get_item is transfer full, so we need to drop the references we get from it. This was showing up while testing the GL texture cache in GtkGLArea.
This commit is contained in:
parent
5e7b3030b9
commit
18dc994de7
@ -120,6 +120,9 @@ recordings_list_row_selected (GtkListBox *box,
|
||||
}
|
||||
|
||||
gtk_tree_view_expand_all (GTK_TREE_VIEW (priv->render_node_tree));
|
||||
|
||||
if (recording)
|
||||
g_object_unref (recording);
|
||||
}
|
||||
|
||||
static void
|
||||
@ -773,6 +776,8 @@ gtk_inspector_recorder_recordings_list_create_widget (gpointer item,
|
||||
{
|
||||
GtkInspectorRecording *r = g_list_model_get_item (priv->recordings, i);
|
||||
|
||||
g_object_unref (r);
|
||||
|
||||
if (r == recording)
|
||||
break;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user