[Commits] [SCM] claws branch, gtk3, updated. 4.0.0-236-gb4a807872

wwp at claws-mail.org wwp at claws-mail.org
Mon Sep 27 18:27:24 CEST 2021


The branch, gtk3 has been updated
       via  b4a80787218ddf6b2ed728cbc16eeb4519816a72 (commit)
      from  d845ea3991d780129963db79a2891a0bf0aee3fa (commit)

Summary of changes:
 src/prefs_toolbar.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)


- Log -----------------------------------------------------------------
commit b4a80787218ddf6b2ed728cbc16eeb4519816a72
Author: wwp <subscript at free.fr>
Date:   Mon Sep 27 18:26:59 2021 +0200

    Fix CID 1491085: (possible) use after free.

diff --git a/src/prefs_toolbar.c b/src/prefs_toolbar.c
index 65d66b687..907794f10 100644
--- a/src/prefs_toolbar.c
+++ b/src/prefs_toolbar.c
@@ -1304,13 +1304,14 @@ static void set_visible_if_not_text(GtkTreeViewColumn *col,
 		gtk_tree_model_get(model, iter,
 				   SET_ICON, &pixbuf,
 				   -1);
-		/* note getting a pixbuf from a tree model increases
+		/* note: getting a pixbuf from a tree model increases
 		 * its refcount ... */
-		if (pixbuf != NULL)
-			g_object_unref(pixbuf);
 
 		g_object_set(renderer, "visible", TRUE, NULL);
 		g_object_set(renderer, "pixbuf",  pixbuf, NULL);
+
+		if (pixbuf != NULL)
+			g_object_unref(pixbuf);
 	}
 }
 

-----------------------------------------------------------------------


hooks/post-receive
-- 
Claws Mail


More information about the Commits mailing list