diff options
Diffstat (limited to 'demux/timeline.c')
-rw-r--r-- | demux/timeline.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/demux/timeline.c b/demux/timeline.c index 86e4921280..f771155e18 100644 --- a/demux/timeline.c +++ b/demux/timeline.c @@ -16,12 +16,11 @@ struct timeline *timeline_load(struct mpv_global *global, struct mp_log *log, .log = log, .cancel = demuxer->cancel, .demuxer = demuxer, - .track_layout = demuxer, }; demuxer->desc->load_timeline(tl); - if (tl->num_parts) + if (tl->num_pars) return tl; timeline_destroy(tl); return NULL; @@ -31,14 +30,10 @@ void timeline_destroy(struct timeline *tl) { if (!tl) return; - // (Sub timeline elements may depend on allocations in the parent one.) - timeline_destroy(tl->next); for (int n = 0; n < tl->num_sources; n++) { struct demuxer *d = tl->sources[n]; - if (d != tl->demuxer && d != tl->track_layout) + if (d != tl->demuxer) demux_free(d); } - if (tl->track_layout && tl->track_layout != tl->demuxer) - demux_free(tl->track_layout); talloc_free(tl); } |