path: root/
diff options
authorwm4 <wm4@nowhere>2019-06-19 18:56:08 +0200
committerwm4 <wm4@nowhere>2019-09-19 20:37:05 +0200
commit2b37f9a984cc00374d2506d26967e4a248cceb14 (patch)
treee15ad49a7904ed75291586a7457ec6d4d0b023d1 /
parente40885d963f8b60d83aa5ea8104985dd20af262f (diff)
demux: never set demux->stream for timeline mess
Timeline (demux_timeline, for EDL and mkv ordered chapters) are a mess, because it's the only nested demuxer case. Part of the mess comes from shared struct stream pointers. This makes no sense, because the wrapper (demux_timeline) doesn't have any business setting it. Try to lessen it by not passing down streams. Instead, pass down NULL. This prevents unintended interference, and tightens the ownership rules. Now a demuxer always owns its stream. On the other hand, demuxer->stream can now be NULL. This was never the case before, and consequently there will be new bugs. At least they will be spotted, because they've been bugs before. struct stream is also used to access stream properties (such as whether something is considered a network stream). Most of these have been mirrored in struct demuxer (because the frontend has been forbidden to access struct stream because of threading). But during initialization was still used, so introduce an awkward struct parent_stream_info, which unifies these. Commit e0419fb181b3d2 changed demux_is_network_cached() to use demuxer->stream->streaming instead of demuxer->is_network. To enable timeline stuff to use the cache anyway, change it so that both flags can contribute to it. The stream NULL-check is obviously due to changes in this commit.
Diffstat (limited to '')
0 files changed, 0 insertions, 0 deletions