mirror of
https://github.com/webmproject/libwebp.git
synced 2025-07-16 13:59:51 +02:00
Fix a boundary case in BackwardReferencesHashChainDistanceOnly.
The optimization for (len != MIN_LENGTH) actually only holds for (len > MIN_LENGTH) but (len < MIN_LENGTH) can now happen as len can be changed in the loop before. Change-Id: I3f9f91a540206c80385c5fba96c3d64ab9536752
This commit is contained in:
@ -1240,7 +1240,7 @@ static int BackwardReferencesHashChainDistanceOnly(
|
||||
}
|
||||
goto next_symbol;
|
||||
}
|
||||
if (len != MIN_LENGTH) {
|
||||
if (len > MIN_LENGTH) {
|
||||
int code_min_length;
|
||||
double cost_total;
|
||||
offset = HashChainFindOffset(hash_chain, i);
|
||||
|
Reference in New Issue
Block a user