Commit 010b24f8 authored by antirez's avatar antirez
Browse files

ACL: set the command ID while populating the commands table.

parent 91f1d802
......@@ -2202,6 +2202,8 @@ void populateCommandTable(void) {
char *f = c->sflags;
int retval1, retval2;
/* Translate the command string flags description into an actual
* set of flags. */
while(*f != '\0') {
switch(*f) {
case 'w': c->flags |= CMD_WRITE; break;
......@@ -2222,6 +2224,8 @@ void populateCommandTable(void) {
f++;
}
c->id = j; /* Sequential ID for each command. Used for ACLs. */
retval1 = dictAdd(server.commands, sdsnew(c->name), c);
/* Populate an additional dictionary that will be unaffected
* by rename-command statements in redis.conf. */
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment