1
0
mirror of https://github.com/mpv-player/mpv synced 2024-12-27 09:32:40 +00:00

demux_mkv: avoid endless loop with broken files

Fixes #1457.
This commit is contained in:
wm4 2015-01-12 01:33:35 +01:00
parent 2c9180f47b
commit 866a5a12b9

View File

@ -307,7 +307,7 @@ static bstr demux_mkv_decode(struct mp_log *log, mkv_track_t *track,
dest = NULL;
goto error;
}
dstlen *= 2;
dstlen = MPMAX(1, 2 * dstlen);
}
size = dstlen - out_avail;
} else if (enc->comp_algo == 3) {