From fb33e286b5c23dbe8d0aeaf63cd3490bed3906e3 Mon Sep 17 00:00:00 2001 From: Uoti Urpala Date: Sat, 26 Apr 2008 10:44:59 +0300 Subject: Move global mconfig to mpctx The global was used in the function cfg_include which handles the -include option. Make the address available in that function by creating a new dynamically allocated option in m_config_new that has the address in the option's private data. asxparser.c also used the global. Making it available through all ways the code could get called required a number of relatively straightforward changes to playtree and menu code. --- command.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'command.c') diff --git a/command.c b/command.c index cb277ac5c5..6eff9f1760 100644 --- a/command.c +++ b/command.c @@ -2605,7 +2605,7 @@ int run_command(MPContext *mpctx, mp_cmd_t *cmd) break; case MP_CMD_LOADLIST:{ - play_tree_t *e = parse_playlist_file(cmd->args[0].v.s); + play_tree_t *e = parse_playlist_file(mpctx->mconfig, cmd->args[0].v.s); if (!e) mp_msg(MSGT_CPLAYER, MSGL_ERR, MSGTR_PlaylistLoadUnable, cmd->args[0].v.s); -- cgit v1.2.3