mirror of
https://github.com/fluencelabs/redis
synced 2025-03-19 09:00:51 +00:00
Verify pairs are provided after subcommands
Fixes https://github.com/antirez/redis/issues/3639
This commit is contained in:
parent
6eb0c52d4c
commit
5dc4fe1529
@ -1521,7 +1521,7 @@ void zaddGenericCommand(client *c, int flags) {
|
||||
/* After the options, we expect to have an even number of args, since
|
||||
* we expect any number of score-element pairs. */
|
||||
elements = c->argc-scoreidx;
|
||||
if (elements % 2) {
|
||||
if (elements % 2 || !elements) {
|
||||
addReply(c,shared.syntaxerr);
|
||||
return;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user