Fix HLL corruption bug

This commit is contained in:
John Sully 2019-07-29 18:11:52 -04:00
parent cf2df9829c
commit c6d5347a22

View File

@ -701,6 +701,7 @@ int hllSparseSet(robj *o, long index, uint8_t count) {
first += span; first += span;
} }
if (span == 0) return -1; /* Invalid format. */ if (span == 0) return -1; /* Invalid format. */
if (span >= end) return -1; /* Invalid format. */
next = HLL_SPARSE_IS_XZERO(p) ? p+2 : p+1; next = HLL_SPARSE_IS_XZERO(p) ? p+2 : p+1;
if (next >= end) next = NULL; if (next >= end) next = NULL;