]> git.ipfire.org Git - thirdparty/rspamd.git/commitdiff
[Fix] Set proper element when reading data from Sentinel
authorVsevolod Stakhov <vsevolod@highsecure.ru>
Tue, 4 Dec 2018 16:20:39 +0000 (16:20 +0000)
committerVsevolod Stakhov <vsevolod@highsecure.ru>
Tue, 4 Dec 2018 16:20:39 +0000 (16:20 +0000)
Issue: #2663
Closes: #2663
lualib/lua_redis.lua

index 6f0a437b7aaae86327f40d9d616cf4ef0dfccd3a..b246899db73faf2f36a9b4c5bef36c7dcd86b413 100644 (file)
@@ -144,10 +144,12 @@ local function redis_query_sentinel(ev_base, params, initialised)
     end
 
     local read_servers_str = table.concat(read_servers_tbl, ',')
-    local write_servers_str = table.concat(read_servers_tbl, ',')
+    local write_servers_str = table.concat(write_servers_tbl, ',')
 
     lutil.debugm(N, rspamd_config,
-        'new servers list: %s read; %s write', read_servers_str, write_servers_str)
+        'new servers list: %s read; %s write',
+        read_servers_str,
+        write_servers_str)
 
     if read_servers_str ~= params.read_servers_str then
       local upstream_list = require "rspamd_upstream_list"