[Commits] [SCM] claws branch, gtk3, updated. 4.0.0-251-gecb3e3e74

wwp at claws-mail.org wwp at claws-mail.org
Tue Sep 28 17:13:21 CEST 2021


The branch, gtk3 has been updated
       via  ecb3e3e748be5a6e89056d31960abde19fe209bd (commit)
      from  15814dd06ce1461b1b52efc33ae6b0b7da7dd036 (commit)

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


- Log -----------------------------------------------------------------
commit ecb3e3e748be5a6e89056d31960abde19fe209bd
Author: wwp <subscript at free.fr>
Date:   Tue Sep 28 17:13:07 2021 +0200

    Fix CID 1491066: resource leak.

diff --git a/src/plugins/clamd/clamav_plugin.c b/src/plugins/clamd/clamav_plugin.c
index 8035fd678..ab3d4e0b7 100644
--- a/src/plugins/clamd/clamav_plugin.c
+++ b/src/plugins/clamd/clamav_plugin.c
@@ -86,7 +86,7 @@ static gboolean scan_func(GNode *node, gpointer data)
 	response buf;
 	int max;
 	GStatBuf info;
-	gchar* msg;
+	gchar* msg, *name;
 
 	outfile = procmime_get_tmp_file_name(mimeinfo);
 	if (procmime_get_part(outfile, mimeinfo) < 0)
@@ -116,8 +116,10 @@ static gboolean scan_func(GNode *node, gpointer data)
 						}
 						break;
 					case VIRUS: 
+						name = clamd_get_virus_name(buf.msg);
 						msg = g_strconcat(_("Detected %s virus."),
-							clamd_get_virus_name(buf.msg), NULL);
+							name, NULL);
+						g_free(name);
 						g_warning("%s", msg);
 						debug_print("no_recv: %d\n", prefs_common_get_prefs()->no_recv_err_panel);
 						if (prefs_common_get_prefs()->no_recv_err_panel) {

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


hooks/post-receive
-- 
Claws Mail


More information about the Commits mailing list