[Commits] [SCM] claws branch, gtk3, updated. 4.0.0-260-ge3048e92f

wwp at claws-mail.org wwp at claws-mail.org
Wed Sep 29 12:45:08 CEST 2021


The branch, gtk3 has been updated
       via  e3048e92f12db05a9e18328f72acd14094e3f97f (commit)
      from  45c87cf44dae2b33714bf7af487fb07fbc099bff (commit)

Summary of changes:
 src/plugins/managesieve/sieve_editor.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)


- Log -----------------------------------------------------------------
commit e3048e92f12db05a9e18328f72acd14094e3f97f
Author: wwp <subscript at free.fr>
Date:   Wed Sep 29 12:43:22 2021 +0200

    Fix CID 1491362: dereference after null check.
    Fix CID 1491278: (neutral) use after free (but still better to disable callbacks before freeing).

diff --git a/src/plugins/managesieve/sieve_editor.c b/src/plugins/managesieve/sieve_editor.c
index 17c3c0ed0..8149dffd3 100644
--- a/src/plugins/managesieve/sieve_editor.c
+++ b/src/plugins/managesieve/sieve_editor.c
@@ -164,7 +164,7 @@ static void sieve_editor_append_status(SieveEditorPage *page,
 	GtkLabel *label = GTK_LABEL(page->status_text);
 	const gchar *prev_status = gtk_label_get_text(label);
 	const gchar *sep = prev_status && prev_status[0] ? "\n" : "";
-	gchar *status = g_strconcat(prev_status, sep, new_status, NULL);
+	gchar *status = g_strconcat(prev_status ? prev_status : "", sep, new_status, NULL);
 	gtk_label_set_text(label, status);
 	g_free(status);
 }
@@ -422,8 +422,8 @@ static void sieve_editor_destroy(SieveEditorPage *page)
 void sieve_editor_close(SieveEditorPage *page)
 {
 	editors = g_slist_remove(editors, (gconstpointer)page);
-	sieve_editor_destroy(page);
 	sieve_sessions_discard_callbacks(page);
+	sieve_editor_destroy(page);
 }
 
 static gboolean sieve_editor_confirm_close(SieveEditorPage *page)

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


hooks/post-receive
-- 
Claws Mail


More information about the Commits mailing list