m_config: add a special define to access main config

Passing NULL to mp_get_config_group() returns the main option struct.
This is just a dumb hack to deal with inconsistencies caused by legacy
things (as I'll claim), and will probably be changed in the future. So
before littering the whole code base with hard to find NULL parameters,
require using callers an easy to find separate define.
This commit is contained in:
wm4
2018-05-21 15:21:09 +02:00
parent fb22bf2317
commit fe6b2f9103
2 changed files with 7 additions and 5 deletions

View File

@@ -517,7 +517,7 @@ void build_ordered_chapter_timeline(struct timeline *tl)
.global = tl->global,
.tl = tl,
.demuxer = demuxer,
.opts = mp_get_config_group(ctx, tl->global, NULL),
.opts = mp_get_config_group(ctx, tl->global, GLOBAL_CONFIG),
};
if (!ctx->opts->ordered_chapters || !demuxer->access_references) {