mirror of
https://github.com/ckolivas/lrzip.git
synced 2026-04-07 15:23:57 +00:00
Try limiting stream_read in unzip_literal and just returning how much was read.
This commit is contained in:
parent
9a3bfe33d1
commit
3879807865
2 changed files with 10 additions and 6 deletions
2
stream.c
2
stream.c
|
|
@ -1259,7 +1259,7 @@ i64 read_stream(void *ss, int stream, uchar *p, i64 len)
|
|||
while (len) {
|
||||
i64 n;
|
||||
|
||||
n = MIN(sinfo->s[stream].buflen-sinfo->s[stream].bufp, len);
|
||||
n = MIN(sinfo->s[stream].buflen - sinfo->s[stream].bufp, len);
|
||||
|
||||
if (n > 0) {
|
||||
memcpy(p, sinfo->s[stream].buf + sinfo->s[stream].bufp, n);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue