diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2017-01-17 16:52:45 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2017-01-17 16:52:45 +0000 |
commit | 7672a0ae2ef3ea7d6c79f1f9de5f3d9d1cd84b85 (patch) | |
tree | 080b389d00619447bfc62501be825d0f59dec49d /src/rspamd_proxy.c | |
parent | f4149123c25d3850197acb93265c4a02c522a497 (diff) | |
download | rspamd-7672a0ae2ef3ea7d6c79f1f9de5f3d9d1cd84b85.tar.gz rspamd-7672a0ae2ef3ea7d6c79f1f9de5f3d9d1cd84b85.zip |
[Fix] Plug reload leaks
Diffstat (limited to 'src/rspamd_proxy.c')
-rw-r--r-- | src/rspamd_proxy.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/rspamd_proxy.c b/src/rspamd_proxy.c index d4a2c1b57..8e2b205b7 100644 --- a/src/rspamd_proxy.c +++ b/src/rspamd_proxy.c @@ -620,7 +620,8 @@ init_rspamd_proxy (struct rspamd_config *cfg) type = g_quark_try_string ("rspamd_proxy"); - ctx = g_malloc0 (sizeof (struct rspamd_proxy_ctx)); + ctx = rspamd_mempool_alloc (cfg->cfg_pool, + sizeof (struct rspamd_proxy_ctx)); ctx->magic = rspamd_rspamd_proxy_magic; ctx->timeout = 10.0; ctx->upstreams = g_hash_table_new (rspamd_strcase_hash, rspamd_strcase_equal); |