mirror of
https://github.com/intel/isa-l.git
synced 2025-01-31 10:31:12 +01:00
igzip: Fix deflate for large buffers
Change-Id: I1993e0a6d3aa36c68af80229329316b2e0616a09 Signed-off-by: Roy Oursler <roy.j.oursler@intel.com>
This commit is contained in:
parent
995d420c6b
commit
2a292689ec
@ -1273,7 +1273,7 @@ int isal_deflate(struct isal_zstream *stream)
|
||||
|
||||
stream->flush = flush_type;
|
||||
stream->end_of_stream = end_of_stream;
|
||||
} while (stream->total_in < total_start + hist_size && avail_in > 0
|
||||
} while (stream->total_in - total_start < hist_size && avail_in > 0
|
||||
&& stream->avail_out > 0);
|
||||
|
||||
stream->total_in += state->b_bytes_valid - state->b_bytes_processed;
|
||||
@ -1282,7 +1282,7 @@ int isal_deflate(struct isal_zstream *stream)
|
||||
|
||||
if (stream->avail_in > 0 && stream->avail_out > 0) {
|
||||
/* Due to exiting conditions for the while loop, we know that
|
||||
* stream->total_in < total_start + hist_size */
|
||||
* stream->total_in - total_start < hist_size */
|
||||
stream->next_in -= state->b_bytes_valid - state->b_bytes_processed;
|
||||
stream->avail_in += state->b_bytes_valid - state->b_bytes_processed;
|
||||
stream->total_in -= state->b_bytes_valid - state->b_bytes_processed;
|
||||
|
Loading…
x
Reference in New Issue
Block a user