diff options
author | wm4 <wm4@nowhere> | 2014-01-04 19:00:01 +0100 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2014-01-06 20:22:26 +0100 |
commit | 29c74b42b4f9edc6a197ee884d723f8901c8de97 (patch) | |
tree | 149c1fad7311ec5e14092cca9f891192b8123942 /player | |
parent | 4b2a3e50e25f488e170c2a77c048d38b6fb3f85a (diff) | |
download | mpv-29c74b42b4f9edc6a197ee884d723f8901c8de97.tar.bz2 mpv-29c74b42b4f9edc6a197ee884d723f8901c8de97.tar.xz |
demux_subreader: reject file if not opened by --sub
demux_subreader.c contains the old MPlayer subtitle parser, and I have
absolutely no confidence in this (very crappy) code. There might be
one or two security risks associated with running that code on
arbitrary input.
Diffstat (limited to 'player')
-rw-r--r-- | player/loadfile.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/player/loadfile.c b/player/loadfile.c index 14faeb08c9..f35c63fa38 100644 --- a/player/loadfile.c +++ b/player/loadfile.c @@ -776,6 +776,7 @@ static struct track *open_external_file(struct MPContext *mpctx, char *filename, opts->stream_cache_seek_min_percent); struct demuxer_params params = { .ass_library = mpctx->ass_library, // demux_libass requires it + .expect_subtitle = filter == STREAM_SUB, }; struct demuxer *demuxer = demux_open(stream, demuxer_name, ¶ms, mpctx->global); |