mirror of https://github.com/mpv-player/mpv
demux_edl: correct warning on duplicate parameters
A parameter that is actually used is removed from the param_names[] array, so we can report unused parameters. This also happened on duplicate parameters, so adjust the warning to make it less confusing. (In any case, you're not supposed to provide duplicate parameters.)
This commit is contained in:
parent
3d225ad275
commit
9f5b9011d6
|
@ -292,8 +292,10 @@ static struct tl_root *parse_edl(bstr str, struct mp_log *log)
|
|||
}
|
||||
if (ctx.error)
|
||||
goto error;
|
||||
for (int n = 0; n < ctx.num_params; n++)
|
||||
mp_warn(log, "Unknown parameter: '%.*s'\n", BSTR_P(ctx.param_names[n]));
|
||||
for (int n = 0; n < ctx.num_params; n++) {
|
||||
mp_warn(log, "Unknown or duplicate parameter: '%.*s'\n",
|
||||
BSTR_P(ctx.param_names[n]));
|
||||
}
|
||||
}
|
||||
assert(root->num_pars);
|
||||
for (int n = 0; n < root->num_pars; n++) {
|
||||
|
|
Loading…
Reference in New Issue