From 1b257d00ca33436bb144df454ad9c9dba0d0453d Mon Sep 17 00:00:00 2001 From: antirez Date: Thu, 31 Jan 2019 18:32:49 +0100 Subject: [PATCH] ACL: check arity of LIST / USERS subcommand. --- src/acl.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/acl.c b/src/acl.c index cf46ef812..58ffece34 100644 --- a/src/acl.c +++ b/src/acl.c @@ -973,7 +973,9 @@ void aclCommand(client *c) { addReplyBulkCBuffer(c,thispat,sdslen(thispat)); } } - } else if (!strcasecmp(sub,"list") || !strcasecmp(sub,"users")) { + } else if ((!strcasecmp(sub,"list") || !strcasecmp(sub,"users")) && + c->argc == 2) + { int justnames = !strcasecmp(sub,"users"); addReplyArrayLen(c,raxSize(Users)); raxIterator ri;