|
|
|
@ -648,7 +648,7 @@ int mszip_decompress(struct mszip_stream *zip, uint32_t out_bytes) { |
|
|
|
|
|
|
|
|
|
/* flush out any stored-up bytes before we begin */ |
|
|
|
|
i = zip->o_end - zip->o_ptr; |
|
|
|
|
if ((off_t) i > out_bytes) i = (int) out_bytes; |
|
|
|
|
if (((off_t) i > out_bytes) && ((int) out_bytes >= 0)) i = (int) out_bytes; |
|
|
|
|
if (i) { |
|
|
|
|
if (zip->wflag && (ret = mspack_write(zip->ofd, zip->o_ptr, i, zip->file)) != CL_SUCCESS) { |
|
|
|
|
return zip->error = ret; |
|
|
|
@ -1120,7 +1120,7 @@ int lzx_decompress(struct lzx_stream *lzx, uint32_t out_bytes) { |
|
|
|
|
|
|
|
|
|
/* flush out any stored-up bytes before we begin */ |
|
|
|
|
i = lzx->o_end - lzx->o_ptr; |
|
|
|
|
if ((off_t) i > out_bytes) i = (int) out_bytes; |
|
|
|
|
if (((off_t) i > out_bytes) && ((int) out_bytes >= 0)) i = (int) out_bytes; |
|
|
|
|
if (i) { |
|
|
|
|
if (lzx->wflag && (ret = mspack_write(lzx->ofd, lzx->o_ptr, i, lzx->file)) != CL_SUCCESS) { |
|
|
|
|
return lzx->error = ret; |
|
|
|
@ -1852,7 +1852,7 @@ int qtm_decompress(struct qtm_stream *qtm, uint32_t out_bytes) { |
|
|
|
|
|
|
|
|
|
/* flush out any stored-up bytes before we begin */ |
|
|
|
|
i = qtm->o_end - qtm->o_ptr; |
|
|
|
|
if ((off_t) i > out_bytes) i = (int) out_bytes; |
|
|
|
|
if (((off_t) i > out_bytes) && ((int) out_bytes >= 0)) i = (int) out_bytes; |
|
|
|
|
if (i) { |
|
|
|
|
if (qtm->wflag && (ret = mspack_write(qtm->ofd, qtm->o_ptr, i, qtm->file)) != CL_SUCCESS) { |
|
|
|
|
return qtm->error = ret; |
|
|
|
|