Skip to content

Commit

Permalink
rebasing
Browse files Browse the repository at this point in the history
Signed-off-by: Sarthak Aggarwal <[email protected]>
  • Loading branch information
sarthakaggarwal97 committed Dec 20, 2024
1 parent 35cf64f commit 094ee75
Showing 1 changed file with 18 additions and 18 deletions.
36 changes: 18 additions & 18 deletions src/networking.c
Original file line number Diff line number Diff line change
Expand Up @@ -3708,10 +3708,10 @@ static int parseClientFiltersOrReply(client *c, int index, clientFilter *filter)
return C_ERR;
}
index += 2;
} else if (!strcasecmp(c->argv[i]->ptr, "minidle") && moreargs) {
} else if (!strcasecmp(c->argv[index]->ptr, "minidle") && moreargs) {
long long tmp;

if (getLongLongFromObjectOrReply(c, c->argv[i + 1], &tmp,
if (getLongLongFromObjectOrReply(c, c->argv[index + 1], &tmp,
"minidle is not an integer or out of range") != C_OK)
return C_ERR;
if (tmp <= 0) {
Expand All @@ -3720,22 +3720,22 @@ static int parseClientFiltersOrReply(client *c, int index, clientFilter *filter)
}

filter->min_idle = tmp;
i += 2;
} else if (!strcasecmp(c->argv[i]->ptr, "flags") && moreargs) {
filter->flags = c->argv[i + 1]->ptr;
i += 2;
} else if (!strcasecmp(c->argv[i]->ptr, "name") && moreargs) {
filter->name = c->argv[i + 1]->ptr;
i += 2;
} else if (!strcasecmp(c->argv[i]->ptr, "pattern") && moreargs) {
filter->pattern = createObject(OBJ_STRING, sdsnew(c->argv[i + 1]->ptr));
i += 2;
} else if (!strcasecmp(c->argv[i]->ptr, "channel") && moreargs) {
filter->channel = createObject(OBJ_STRING, sdsnew(c->argv[i + 1]->ptr));
i += 2;
} else if (!strcasecmp(c->argv[i]->ptr, "shardchannel") && moreargs) {
filter->shard_channel = createObject(OBJ_STRING, sdsnew(c->argv[i + 1]->ptr));
i += 2;
index += 2;
} else if (!strcasecmp(c->argv[index]->ptr, "flags") && moreargs) {
filter->flags = c->argv[index + 1]->ptr;
index += 2;
} else if (!strcasecmp(c->argv[index]->ptr, "name") && moreargs) {
filter->name = c->argv[index + 1]->ptr;
index += 2;
} else if (!strcasecmp(c->argv[index]->ptr, "pattern") && moreargs) {
filter->pattern = createObject(OBJ_STRING, sdsnew(c->argv[index + 1]->ptr));
index += 2;
} else if (!strcasecmp(c->argv[index]->ptr, "channel") && moreargs) {
filter->channel = createObject(OBJ_STRING, sdsnew(c->argv[index + 1]->ptr));
index += 2;
} else if (!strcasecmp(c->argv[index]->ptr, "shardchannel") && moreargs) {
filter->shard_channel = createObject(OBJ_STRING, sdsnew(c->argv[index + 1]->ptr));
index += 2;
} else {
addReplyErrorObject(c, shared.syntaxerr);
return C_ERR;
Expand Down

0 comments on commit 094ee75

Please sign in to comment.