options: fix -profile parsing after 2db33ab48c
commitdaafc5a368266dc2206b7da0c107b98e0ca042d6
authorUoti Urpala <uau@mplayer2.org>
Sat, 7 May 2011 16:26:12 +0000 (7 19:26 +0300)
committerUoti Urpala <uau@mplayer2.org>
Sat, 7 May 2011 16:44:58 +0000 (7 19:44 +0300)
treeacd9c120329b97ac4f764319251374a6fc17229d
parentb68f9fef32971095836ea6bbeb2f12af417120d2
options: fix -profile parsing after 2db33ab48c

Commit 2db33ab48cfa785 ("options: support string list separators other
than ','") started using the "priv" field in options of string list
type to store the separator character. However, the "profile" option
has a custom type which uses the same parsing function but uses the
"priv" field for another purpose. As a result "-profile" parsing used
a "random" character as the separator instead of ','; at least uses
which depended on ',' working were likely to fail, and if the
separator used happened to be a character occurring in the profile
name then any use of -profile could break. Fix by adding a check in
the parsing function to only read the priv field if the option type is
normal string list.
m_option.c