1
0
mirror of https://github.com/mpv-player/mpv synced 2025-03-11 08:37:59 +00:00

m_option: fix parsing of OP_APPEND for string lists

While parsing through the separators, the OP_APPEND also needs to use 0
for the separator since it is supposed to be unescaped. This was missed
in the code reorganization of d2c409c56b.
Keyvalue lists were unaffected because only OP_DELETE and OP_REMOVE use
this code.
This commit is contained in:
Dudemanguy 2025-02-05 11:01:08 -06:00
parent 3717a530ca
commit 493cc877cf

View File

@ -1408,7 +1408,7 @@ static char **separate_input_param(const m_option_t *opt, bstr param,
int *len, int op)
{
char separator = opt->priv ? *(char *)opt->priv : OPTION_LIST_SEPARATOR;
if (op == OP_REMOVE)
if (op == OP_APPEND || op == OP_REMOVE)
separator = 0; // specially handled
struct bstr str = param;
int n = *len;