mirror of https://github.com/google/brotli
Merge pull request #92 from szabadka/master
Fix an error propagation bug in the decoder.
This commit is contained in:
commit
344ea8edb3
|
@ -1605,7 +1605,7 @@ BrotliResult BrotliDecompressStreaming(BrotliInput input, BrotliOutput output,
|
||||||
output, s->ringbuffer + s->partially_written,
|
output, s->ringbuffer + s->partially_written,
|
||||||
(size_t)((pos & s->ringbuffer_mask) - s->partially_written));
|
(size_t)((pos & s->ringbuffer_mask) - s->partially_written));
|
||||||
if (num_written < 0) {
|
if (num_written < 0) {
|
||||||
result = BROTLI_RESULT_ERROR;
|
return BROTLI_RESULT_ERROR;
|
||||||
}
|
}
|
||||||
s->partially_written += num_written;
|
s->partially_written += num_written;
|
||||||
if (s->partially_written < (pos & s->ringbuffer_mask)) {
|
if (s->partially_written < (pos & s->ringbuffer_mask)) {
|
||||||
|
|
Loading…
Reference in New Issue