From bd119d7565ce420c40d7ada24daad3a716ff1e4e Mon Sep 17 00:00:00 2001 From: Kevin Binetruy Date: Tue, 13 Oct 2026 14:55:12 +0000 Subject: [PATCH] MT#55283 redis: print the command timeout in milliseconds Ref #2211 redis_set_timeout() receives the timeout in microseconds (the --redis-cmd-timeout value times 1000) and logged it unconverted, so --redis-cmd-timeout=1000 was reported as: Setting timeout for Redis commands to 1000000 milliseconds Log the value in milliseconds, as the message says. The value passed to hiredis is unchanged. No functional change. Seen in the log of every connection made with a command timeout set; there is no test, as no test reads this line. Change-Id: Ie4d81e4f8baab1969210a589c98245407b088561 (cherry picked from commit 1c447b509b6e057d75edf5f2745614133a9f769a) --- daemon/redis.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/daemon/redis.c b/daemon/redis.c index f40e94821..547a577f4 100644 --- a/daemon/redis.c +++ b/daemon/redis.c @@ -241,7 +241,7 @@ int redis_set_timeout(struct redis* r, int64_t timeout) { tv_cmd = timeval_from_us(timeout); if (redisSetTimeout(r->ctx, tv_cmd)) return -1; - ilog(LOG_INFO, "Setting timeout for Redis commands to %" PRId64 " milliseconds", timeout); + ilog(LOG_INFO, "Setting timeout for Redis commands to %" PRId64 " milliseconds", timeout / 1000); return 0; }