[Commits] [SCM] claws branch, gtk3, updated. 4.0.0-319-gac14ec50d

wwp at claws-mail.org wwp at claws-mail.org
Wed Oct 6 09:40:00 CEST 2021


The branch, gtk3 has been updated
       via  ac14ec50d655c16fd6813526fd18d57d0f0e18ef (commit)
      from  62f60f91dfa86cdcba57aa8b6a7463b14e9bcebc (commit)

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


- Log -----------------------------------------------------------------
commit ac14ec50d655c16fd6813526fd18d57d0f0e18ef
Author: wwp <subscript at free.fr>
Date:   Wed Oct 6 09:16:14 2021 +0200

    Fix CID 1492328: uninitialized ptr read (bound to fix for CID 1491222).

diff --git a/src/msgcache.c b/src/msgcache.c
index 6c815be76..a54c3b823 100644
--- a/src/msgcache.c
+++ b/src/msgcache.c
@@ -331,6 +331,7 @@ gint msgcache_get_memory_usage(MsgCache *cache)
 	GET_CACHE_DATA_INT(tmp_len);	\
 	if (rem_len < tmp_len) {								\
 		g_print("error at rem_len:%d (tmp_len %d)\n", rem_len, tmp_len);		\
+		procmsg_msginfo_free(&msginfo); \
 		error = TRUE;									\
 		goto bail_err;									\
 	}											\
@@ -663,9 +664,10 @@ MsgCache *msgcache_read_cache(FolderItem *item, const gchar *cache_file)
 		char *walk_data = cache_data+ftell(fp);
 
 		while(rem_len > 0) {
-			GET_CACHE_DATA_INT(num);
-			
 			msginfo = procmsg_msginfo_new();
+
+			GET_CACHE_DATA_INT(num);
+
 			msginfo->msgnum = num;
 			memusage += sizeof(MsgInfo);
 

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


hooks/post-receive
-- 
Claws Mail


More information about the Commits mailing list