From: Vsevolod Stakhov Date: Fri, 13 Jan 2017 16:55:57 +0000 (+0000) Subject: [Minor] Fix potential leak in lua send fuzzy command X-Git-Tag: 1.5.0~348 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e568f3d33b8122ce27ccbc36ca58024274e89bcf;p=thirdparty%2Frspamd.git [Minor] Fix potential leak in lua send fuzzy command --- diff --git a/src/plugins/fuzzy_check.c b/src/plugins/fuzzy_check.c index 955d6fd860..26ad295faf 100644 --- a/src/plugins/fuzzy_check.c +++ b/src/plugins/fuzzy_check.c @@ -2874,6 +2874,8 @@ fuzzy_check_lua_process_learn (struct rspamd_task *task, if (commands != NULL) { res = fuzzy_check_send_lua_learn (rule, task, commands, saved, err); + rspamd_mempool_add_destructor (task->task_pool, + rspamd_ptr_array_free_hard, commands); } if (res) {