summaryrefslogtreecommitdiffstats
path: root/player
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2015-05-07 21:03:14 +0200
committerDiogo Franco (Kovensky) <diogomfranco@gmail.com>2015-05-08 16:38:46 +0900
commit375437f204e8ed670c49158c73f8ae8e1bb096e6 (patch)
treecde4676ff3b260bfec747d13042a145e6990547e /player
parentceea08d7fe337738aec9281b2cdf749b7e946799 (diff)
downloadmpv-375437f204e8ed670c49158c73f8ae8e1bb096e6.tar.bz2
mpv-375437f204e8ed670c49158c73f8ae8e1bb096e6.tar.xz
m_config: make m_config_set_profile() use a name
Is simpler and avoids exposing profile structs to a degree. (cherry picked from commit 036a49478ff6cc19abfa06b7807bd4653eb9ce33)
Diffstat (limited to 'player')
-rw-r--r--player/configfiles.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/player/configfiles.c b/player/configfiles.c
index b7d3795f60..52cd837ab7 100644
--- a/player/configfiles.c
+++ b/player/configfiles.c
@@ -84,7 +84,7 @@ void mp_parse_cfgfiles(struct MPContext *mpctx)
load_all_cfgfiles(mpctx, section, "mpv.conf|config");
if (encoding)
- m_config_set_profile(conf, m_config_add_profile(conf, SECT_ENCODE), 0);
+ m_config_set_profile(conf, SECT_ENCODE, 0);
}
static int try_load_config(struct MPContext *mpctx, const char *file, int flags)
@@ -143,7 +143,7 @@ static void mp_auto_load_profile(struct MPContext *mpctx, char *category,
m_profile_t *p = m_config_get_profile0(mpctx->mconfig, t);
if (p) {
MP_INFO(mpctx, "Auto-loading profile '%s'\n", t);
- m_config_set_profile(mpctx->mconfig, p, FILE_LOCAL_FLAGS);
+ m_config_set_profile(mpctx->mconfig, t, FILE_LOCAL_FLAGS);
}
}