mirror of
https://github.com/valkey-io/valkey.git
synced 2025-04-20 09:35:54 +08:00
HyperLogLog: fix the fix of a corruption bug.
This commit is contained in:
parent
6ef5a0cbbb
commit
627abf2289
@ -688,8 +688,7 @@ int hllSparseAdd(robj *o, unsigned char *ele, size_t elesize) {
|
||||
p += oplen;
|
||||
first += span;
|
||||
}
|
||||
if (span == 0) return -1; /* Invalid format. */
|
||||
if (span >= end) return -1; /* Invalid format. */
|
||||
if (span == 0 || p >= end) return -1; /* Invalid format. */
|
||||
|
||||
next = HLL_SPARSE_IS_XZERO(p) ? p+2 : p+1;
|
||||
if (next >= end) next = NULL;
|
||||
|
Loading…
x
Reference in New Issue
Block a user