diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2019-03-13 15:01:18 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2019-03-13 15:01:55 +0000 |
commit | f7aee39a9dc81ae437e1dcc651a7335a7ae071d3 (patch) | |
tree | 491a5422b5e32feabad05fca0cdb9ae196f731a5 /src/fuzzy_storage.c | |
parent | 376b5cac00888b7d3203f2c3e5611b0d25044c6b (diff) | |
download | rspamd-f7aee39a9dc81ae437e1dcc651a7335a7ae071d3.tar.gz rspamd-f7aee39a9dc81ae437e1dcc651a7335a7ae071d3.zip |
[Fix] Fix various issues found by PVS Studio
https://www.viva64.com/
Diffstat (limited to 'src/fuzzy_storage.c')
-rw-r--r-- | src/fuzzy_storage.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/fuzzy_storage.c b/src/fuzzy_storage.c index 7fdce82ae..2054633ad 100644 --- a/src/fuzzy_storage.c +++ b/src/fuzzy_storage.c @@ -599,6 +599,7 @@ rspamd_fuzzy_send_update_mirror (struct rspamd_fuzzy_storage_ctx *ctx, conn->mirror = m; if (conn->up == NULL) { + g_free (conn); msg_err ("cannot select upstream for %s", m->name); return; } @@ -608,6 +609,7 @@ rspamd_fuzzy_send_update_mirror (struct rspamd_fuzzy_storage_ctx *ctx, SOCK_STREAM, TRUE); if (conn->sock == -1) { + g_free (conn); msg_err ("cannot connect upstream for %s", m->name); rspamd_upstream_fail (conn->up, TRUE); return; |