diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2017-01-19 18:09:16 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2017-01-19 18:09:16 +0000 |
commit | f33a30cb3ebfc38245b0a1b5f77771d266a08d41 (patch) | |
tree | 3176d40b26f5e02eaaee975b716e3633d5a3ebc0 /src/libstat/backends | |
parent | 6eb04c230d9cbe42fafadf922149a1c0c648a60e (diff) | |
download | rspamd-f33a30cb3ebfc38245b0a1b5f77771d266a08d41.tar.gz rspamd-f33a30cb3ebfc38245b0a1b5f77771d266a08d41.zip |
[Fix] Some more memory issues are fixed
Diffstat (limited to 'src/libstat/backends')
-rw-r--r-- | src/libstat/backends/redis_backend.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libstat/backends/redis_backend.c b/src/libstat/backends/redis_backend.c index d5df2234e..e869f69ae 100644 --- a/src/libstat/backends/redis_backend.c +++ b/src/libstat/backends/redis_backend.c @@ -602,6 +602,10 @@ rspamd_redis_stat_keys (redisAsyncContext *c, gpointer r, gpointer priv) "users", 0, false); rspamd_upstream_ok (cbdata->selected); + + if (cbdata->inflight == 0) { + rspamd_redis_async_cbdata_cleanup (cbdata); + } } else { if (c->errstr) { @@ -613,10 +617,6 @@ rspamd_redis_stat_keys (redisAsyncContext *c, gpointer r, gpointer priv) rspamd_upstream_fail (cbdata->selected); rspamd_redis_async_cbdata_cleanup (cbdata); } - - if (cbdata->inflight == 0) { - rspamd_redis_async_cbdata_cleanup (cbdata); - } } static void |