Fix LZ4 incorrect size bug

This commit is contained in:
Jaby 2023-04-01 14:56:08 +02:00
parent 8b94760130
commit 5770d4f77e
1 changed files with 3 additions and 2 deletions

View File

@ -70,9 +70,10 @@ namespace JabyEngine {
memcpy(this->dst_adr, data, bytes_copy);
this->state.literal_length -= bytes_copy;
bytes_ready += bytes_copy;
if(this->state.literal_length == 0) {
this->state.step = State::Step::ObtainMatchOffset;
bytes_ready += bytes_copy;
this->state.step = State::Step::ObtainMatchOffset;
}
} break;