From d356f3efd278d38e0b0cfca05b37e40d40118f6a Mon Sep 17 00:00:00 2001 From: wm4 Date: Tue, 21 May 2013 00:04:46 +0200 Subject: m_option: fix -vf-del in profiles We don't bother with option verification (as it happens in profiles), because it's barely possible. --- core/m_option.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'core') diff --git a/core/m_option.c b/core/m_option.c index 1d6c49e851..e291165cbf 100644 --- a/core/m_option.c +++ b/core/m_option.c @@ -2047,8 +2047,9 @@ static bool obj_setting_equals(m_obj_settings_t *a, m_obj_settings_t *b) static int obj_settings_list_del(struct bstr opt_name, struct bstr param, void *dst) { - m_obj_settings_t *obj_list = dst ? VAL(dst) : NULL; - int r = 1; + if (!dst) + return 1; // for profiles; pretend all is ok + m_obj_settings_t *obj_list = VAL(dst); if (dst && !obj_list) { mp_msg(MSGT_CFGPARSER, MSGL_WARN, "Option %.*s: the list is empty.\n", @@ -2103,7 +2104,7 @@ static int obj_settings_list_del(struct bstr opt_name, struct bstr param, } talloc_free(mark_del); - return r; + return 1; } static void free_obj_settings_list(void *dst) -- cgit v1.2.3