chores: update LZ4 (#5102)
This commit is contained in:
@@ -1931,6 +1931,17 @@ read_variable_length(const BYTE** ip, const BYTE* ilimit,
|
|||||||
if (initial_check && unlikely((*ip) >= ilimit)) { /* read limit reached */
|
if (initial_check && unlikely((*ip) >= ilimit)) { /* read limit reached */
|
||||||
return rvl_error;
|
return rvl_error;
|
||||||
}
|
}
|
||||||
|
s = **ip;
|
||||||
|
(*ip)++;
|
||||||
|
length += s;
|
||||||
|
if (unlikely((*ip) > ilimit)) { /* read limit reached */
|
||||||
|
return rvl_error;
|
||||||
|
}
|
||||||
|
/* accumulator overflow detection (32-bit mode only) */
|
||||||
|
if ((sizeof(length) < 8) && unlikely(length > ((Rvl_t)(-1)/2)) ) {
|
||||||
|
return rvl_error;
|
||||||
|
}
|
||||||
|
if (likely(s != 255)) return length;
|
||||||
do {
|
do {
|
||||||
s = **ip;
|
s = **ip;
|
||||||
(*ip)++;
|
(*ip)++;
|
||||||
|
|||||||
Reference in New Issue
Block a user