RESP3: fix genericHgetallCommand() assert.

This commit is contained in:
antirez 2018-12-03 18:08:00 +01:00
parent f39d8334c0
commit f947b3ebe1

View File

@ -793,6 +793,9 @@ void genericHgetallCommand(client *c, int flags) {
}
hashTypeReleaseIterator(hi);
/* Make sure we returned the right number of elements. */
if (flags & OBJ_HASH_KEY && flags & OBJ_HASH_VALUE) count /= 2;
serverAssert(count == length);
}