summaryrefslogtreecommitdiffstats
path: root/demux/demux_lavf.c
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2018-05-18 15:48:14 +0200
committerwm4 <wm4@nowhere>2018-05-24 19:56:35 +0200
commitf9713921a372aa14ea631b0c546d3fbeade32b71 (patch)
treed3a8b403fe6272f5b89e27f82cd210e05d82aa56 /demux/demux_lavf.c
parenta0cce7f775e97aa364d166c278c49df1325e6cc7 (diff)
downloadmpv-f9713921a372aa14ea631b0c546d3fbeade32b71.tar.bz2
mpv-f9713921a372aa14ea631b0c546d3fbeade32b71.tar.xz
demux: add a "cancel" field
Instead of relying on demuxer->stream->cancel. This is better because the stream is potentially closed and replaced.
Diffstat (limited to 'demux/demux_lavf.c')
-rw-r--r--demux/demux_lavf.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/demux/demux_lavf.c b/demux/demux_lavf.c
index a0b5ff7472..41c334d309 100644
--- a/demux/demux_lavf.c
+++ b/demux/demux_lavf.c
@@ -775,8 +775,7 @@ static void update_metadata(demuxer_t *demuxer)
static int interrupt_cb(void *ctx)
{
struct demuxer *demuxer = ctx;
- lavf_priv_t *priv = demuxer->priv;
- return mp_cancel_test(priv->stream->cancel);
+ return mp_cancel_test(demuxer->cancel);
}
static int block_io_open(struct AVFormatContext *s, AVIOContext **pb,