From 828a952c9aa2d2f1427e1f21a6c1202c2191e5a9 Mon Sep 17 00:00:00 2001 From: Ben Boeckel Date: Thu, 26 Sep 2013 02:22:06 -0400 Subject: matroska: fix uninitialized memory accesses with ordered chapters There is uninitialized memory access if the actual size isn't passed along. In the worst case, this can cause a source to be loaded against the uninitialized memory, causing a false count of found versus required sources, preventing the "Failed to find ordered chapter part" message. --- mpvcore/timeline/tl_matroska.c | 1 + 1 file changed, 1 insertion(+) (limited to 'mpvcore/timeline/tl_matroska.c') diff --git a/mpvcore/timeline/tl_matroska.c b/mpvcore/timeline/tl_matroska.c index cad1c3444e..4c3b705f20 100644 --- a/mpvcore/timeline/tl_matroska.c +++ b/mpvcore/timeline/tl_matroska.c @@ -155,6 +155,7 @@ static bool check_file_seg(struct MPContext *mpctx, struct demuxer **sources, { bool was_valid = false; struct demuxer_params params = { + .matroska_num_wanted_uids = num_sources, .matroska_wanted_uids = uid_map, .matroska_wanted_segment = segment, .matroska_was_valid = &was_valid, -- cgit v1.2.3