[Commits] [SCM] claws branch, master, updated. 3.9.2-34-g1a912d8

colin at claws-mail.org colin at claws-mail.org
Thu Jul 25 13:34:09 CEST 2013


The branch master of project "claws" (Claws Mail) has been updated
       via  1a912d8098d9e2e0fe684afb434f17d005d00ba6 (commit)
      from  e84ba2db17ea9afcb3b14e5a3d5a350e63b5cf2f (commit)


- Log -----------------------------------------------------------------
commit 1a912d8098d9e2e0fe684afb434f17d005d00ba6
Author: Colin Leroy <colin at colino.net>
Date:   Thu Jul 25 13:33:55 2013 +0200

    Fix an use-after-free

diff --git a/src/mimeview.c b/src/mimeview.c
index 64bbdd9..caec7d9 100644
--- a/src/mimeview.c
+++ b/src/mimeview.c
@@ -1119,13 +1119,14 @@ static void mimeview_check_data_reset(MimeView *mimeview)
 		pthread_cancel(mimeview->check_data->cancel_th);
 	}
 
-	g_free(mimeview->check_data);
-	mimeview->check_data = NULL;
-
 	if (must_free) {
 		debug_print("freeing deferred mimeinfo\n");
 		procmime_mimeinfo_free_all(mimeview->check_data->siginfo);
 	}
+
+	g_free(mimeview->check_data);
+	mimeview->check_data = NULL;
+
 	if (must_destroy) {
 		debug_print("freeing deferred mimeview\n");
 		mimeview_free_mimeinfo(mimeview);
@@ -1134,7 +1135,6 @@ static void mimeview_check_data_reset(MimeView *mimeview)
 		g_free(mimeview);
 		mimeviews = g_slist_remove(mimeviews, mimeview);
 	}
-
 }
 
 /* GUI update once the checker thread is done or killed */

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

Summary of changes:
 src/mimeview.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)


hooks/post-receive
-- 
Claws Mail


More information about the Commits mailing list