From 658cbe75e6c54c1462f8a8f86df303c3b19e5fc1 Mon Sep 17 00:00:00 2001 From: Vsevolod Stakhov Date: Tue, 17 Jan 2017 17:33:53 +0000 Subject: [Fix] Another try to fix corruption during maps reload --- src/libutil/map.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) (limited to 'src/libutil') diff --git a/src/libutil/map.c b/src/libutil/map.c index ea295e7a4..6a1e76fcd 100644 --- a/src/libutil/map.c +++ b/src/libutil/map.c @@ -294,9 +294,16 @@ free_http_cbdata_dtor (gpointer p) struct rspamd_map *map; map = cbd->map; - cbd->stage = map_finished; + if (cbd->stage >= map_load_file) { + REF_RELEASE (cbd); + } + else { + /* We cannot terminate DNS requests sent */ + cbd->stage = map_finished; + } + msg_warn_map ("connection with http server is terminated: worker is stopping"); - REF_RELEASE (cbd); + } /* -- cgit v1.2.3