From 29ac9aea5de2f395960834b262b3d94f9efedbd8 Mon Sep 17 00:00:00 2001 From: Yossi Gottlieb Date: Wed, 10 Feb 2021 18:38:10 +0200 Subject: [PATCH] Fix Sentinel configuration rewrite. (#8480) The `resolve-hostnames` and `announce-hostnames` parameters were not specified correctly according to the new convention introduced by 1aad55b66. --- src/sentinel.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/sentinel.c b/src/sentinel.c index a87766ebe..fb68fd0ea 100644 --- a/src/sentinel.c +++ b/src/sentinel.c @@ -2077,13 +2077,13 @@ void rewriteConfigSentinelOption(struct rewriteConfigState *state) { */ line = sdscatprintf(sdsempty(), "sentinel resolve-hostnames %s", sentinel.resolve_hostnames ? "yes" : "no"); - rewriteConfigRewriteLine(state,"sentinel",line, + rewriteConfigRewriteLine(state,"sentinel resolve-hostnames",line, sentinel.resolve_hostnames != SENTINEL_DEFAULT_RESOLVE_HOSTNAMES); /* sentinel announce-hostnames. */ line = sdscatprintf(sdsempty(), "sentinel announce-hostnames %s", sentinel.announce_hostnames ? "yes" : "no"); - rewriteConfigRewriteLine(state,"sentinel",line, + rewriteConfigRewriteLine(state,"sentinel announce-hostnames",line, sentinel.announce_hostnames != SENTINEL_DEFAULT_ANNOUNCE_HOSTNAMES); /* For every master emit a "sentinel monitor" config entry. */