From 1e90a8657d19918dc7564f559b96dc3982286ba2 Mon Sep 17 00:00:00 2001 From: Uoti Urpala Date: Tue, 8 May 2012 02:10:39 +0300 Subject: options: simplify option parsing/setting machinery Each option type had three separate operations to copy option values between memory locations: copy between general memory locations ("copy"), copy from general memory to active configuration of the program ("set"), and in the other direction ("save"). No normal option depends on this distinction any more. Change everything to define and use a single "copy" operation only. Change the special options "include" and "profile", which depended on hacky option types, to be special-cased directly in option parsing instead. Remove the now unused option types m_option_type_func and m_option_type_func_param. --- mplayer.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'mplayer.c') diff --git a/mplayer.c b/mplayer.c index e1984e601c..f0c1e2fb83 100644 --- a/mplayer.c +++ b/mplayer.c @@ -857,9 +857,9 @@ static void exit_sighandler(int x) #include "cfg-mplayer.h" -static int cfg_include(m_option_t *conf, char *filename) +static int cfg_include(struct m_config *conf, char *filename) { - return m_config_parse_config_file(conf->priv, filename); + return m_config_parse_config_file(conf, filename); } #define DEF_CONFIG "# Write your default config options here!\n\n\n" -- cgit v1.2.3