[gnome-applets] geyes: avoid use after free defect
- From: Alberts Muktupāvels <muktupavels src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-applets] geyes: avoid use after free defect
- Date: Sun, 21 Mar 2021 17:48:34 +0000 (UTC)
commit 09a4195f038a6678147c37f00a733a927c08af2b
Author: Alberts Muktupāvels <alberts muktupavels gmail com>
Date: Sun Mar 21 19:04:32 2021 +0200
geyes: avoid use after free defect
This is false positive. GtkTreeView refs model.
Coverity CID: #1502722
gnome-applets/geyes/themes.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/gnome-applets/geyes/themes.c b/gnome-applets/geyes/themes.c
index 26570f169..149e83c4c 100644
--- a/gnome-applets/geyes/themes.c
+++ b/gnome-applets/geyes/themes.c
@@ -330,7 +330,6 @@ properties_cb (GSimpleAction *action,
tree = gtk_tree_view_new_with_model (GTK_TREE_MODEL (model));
gtk_tree_view_set_headers_visible (GTK_TREE_VIEW (tree), FALSE);
gtk_label_set_mnemonic_widget (GTK_LABEL (label), tree);
- g_object_unref (model);
gtk_container_add (GTK_CONTAINER (scrolled), tree);
@@ -395,7 +394,9 @@ properties_cb (GSimpleAction *action,
g_dir_close (dir);
}
-
+
+ g_object_unref (model);
+
gtk_box_pack_start (GTK_BOX (control_vbox), scrolled, TRUE, TRUE, 0);
gtk_widget_show_all (pbox);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]