diff --git a/src/t_zset.c b/src/t_zset.c index f641d887c..f5cdec3e4 100644 --- a/src/t_zset.c +++ b/src/t_zset.c @@ -1497,7 +1497,7 @@ void zunionInterGenericCommand(redisClient *c, robj *dstkey, int op) { } /* test if the expected number of keys would overflow */ - if (3+setnum > c->argc) { + if (setnum > c->argc-3) { addReply(c,shared.syntaxerr); return; }