unsigned int zzlLength(robj *zobj) {
unsigned char *zl = zobj->ptr;
+ redisAssert(zobj->encoding == REDIS_ENCODING_ZIPLIST);
return ziplistLen(zl)/2;
}
if ((zobj = lookupKeyReadOrReply(c,key,shared.czero)) == NULL ||
checkType(c,zobj,REDIS_ZSET)) return;
- addReplyLongLong(c,zzlLength(zobj));
+ addReplyLongLong(c,zsLength(zobj));
}
void zscoreCommand(redisClient *c) {