From 71d6760f48fe777a91ade85d23f18badf2c84abe Mon Sep 17 00:00:00 2001 From: antirez Date: Mon, 15 Oct 2018 12:01:17 +0200 Subject: [PATCH] Make comment about nack->consumer test for minidle more obvious. Related to #5437. --- src/t_stream.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/t_stream.c b/src/t_stream.c index 39ee713e0..956a72022 100644 --- a/src/t_stream.c +++ b/src/t_stream.c @@ -2169,8 +2169,10 @@ void xclaimCommand(client *c) { if (nack != raxNotFound) { /* We need to check if the minimum idle time requested * by the caller is satisfied by this entry. - * Note that if nack->consumer is NULL, means the NACK - * is created by FORCE, we should ignore minidle. */ + * + * Note that the nack could be created by FORCE, in this + * case there was no pre-existing entry and minidle should + * be ignored, but in that case nick->consumer is NULL. */ if (nack->consumer && minidle) { mstime_t this_idle = now - nack->delivery_time; if (this_idle < minidle) continue;