ACL: setuser resetkeys implemented.

This commit is contained in:
antirez 2019-01-21 18:18:39 +01:00
parent 2263d6e173
commit 9e5c38282b

View File

@ -244,7 +244,10 @@ int ACLSetUser(user *u, const char *op, ssize_t oplen) {
!strcasecmp(op,"~*"))
{
u->flags |= USER_FLAG_ALLKEYS;
if (u->patterns) listEmpty(u->patterns);
listEmpty(u->patterns);
} else if (!strcasecmp(op,"resetkeys")) {
u->flags &= ~USER_FLAG_ALLKEYS;
listEmpty(u->patterns);
} else if (!strcasecmp(op,"allcommands") ||
!strcasecmp(op,"+@all"))
{