summaryrefslogtreecommitdiffstats
path: root/options/m_option.c
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2015-02-06 15:42:12 +0100
committerwm4 <wm4@nowhere>2015-02-06 15:42:12 +0100
commit1a38741dce3e32218521cc2b00819dac1ccebc3a (patch)
tree6ae7700c29449f1a93a2f7509f49302d5f9f3b22 /options/m_option.c
parentc9558e560eaead8ef3d73c8a3e4cdb5c4ffbfef4 (diff)
downloadmpv-1a38741dce3e32218521cc2b00819dac1ccebc3a.tar.bz2
mpv-1a38741dce3e32218521cc2b00819dac1ccebc3a.tar.xz
options: allow ":" as separator in key-value lists
Before this, unquoted occurrences of ":" lead to parsing errors. There's no reason to reject it, especially since the traditional MPlayer syntax uses ":" as separator. (Which is also the reason why ":" was rejected before: the parser shares this code for handling splitting/quoting, and we merely checked explicitly whether the option was split on ",".)
Diffstat (limited to 'options/m_option.c')
-rw-r--r--options/m_option.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/options/m_option.c b/options/m_option.c
index de65587884..74d6509111 100644
--- a/options/m_option.c
+++ b/options/m_option.c
@@ -1409,7 +1409,7 @@ static int parse_keyvalue_list(struct mp_log *log, const m_option_t *opt,
MP_TARRAY_APPEND(NULL, lst, num, bstrto0(NULL, val));
}
- if (!bstr_eatstart0(&param, ","))
+ if (!bstr_eatstart0(&param, ",") && !bstr_eatstart0(&param, ":"))
break;
}
if (dst)