diff options
author | wm4 <wm4@nowhere> | 2013-08-25 20:40:21 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2013-08-26 10:09:45 +0200 |
commit | 8be9c49fcd8b23463199036eda5fc290ded6d078 (patch) | |
tree | 285f8a1cdcd89c8da9f8a50631a1af5176a783b1 /mpvcore/parser-mpcmd.c | |
parent | ddc973344685b8fee1d7b00e23ba93692d56d7c9 (diff) | |
download | mpv-8be9c49fcd8b23463199036eda5fc290ded6d078.tar.bz2 mpv-8be9c49fcd8b23463199036eda5fc290ded6d078.tar.xz |
core: add a playlist demuxer
Modeled after the old playlist_parser.c, but actually new code, and it
works a bit differently.
Demuxers (and sometimes streams) are the component that should be used
to open files and to determine the file format. This was already done
for subtitles, but playlists still use a separate code path.
Diffstat (limited to 'mpvcore/parser-mpcmd.c')
-rw-r--r-- | mpvcore/parser-mpcmd.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/mpvcore/parser-mpcmd.c b/mpvcore/parser-mpcmd.c index 55615d950e..e85085b808 100644 --- a/mpvcore/parser-mpcmd.c +++ b/mpvcore/parser-mpcmd.c @@ -114,6 +114,7 @@ static bool split_opt(struct parse_state *p) int m_config_parse_mp_command_line(m_config_t *config, struct playlist *files, int argc, char **argv) { + struct MPOpts *opts = config->optstruct; int ret = M_OPT_UNKNOWN; int mode = 0; struct playlist_entry *local_start = NULL; @@ -187,7 +188,7 @@ int m_config_parse_mp_command_line(m_config_t *config, struct playlist *files, if (bstrcmp0(p.arg, "playlist") == 0) { // append the playlist to the local args char *param0 = bstrdup0(NULL, p.param); - struct playlist *pl = playlist_parse_file(param0); + struct playlist *pl = playlist_parse_file(param0, opts); talloc_free(param0); if (!pl) { mp_tmsg(MSGT_CFGPARSER, MSGL_FATAL, |