Current regular expression in get_config_sections allows section names
to consist of alphanumeric character and underscore. Extend it to
also allow the hyphen '-' character.
Signed-off-by: Nikolay Borisov <nborisov@suse.com>
Reviewed-by: Eryu Guan <guaneryu@gmail.com>
Signed-off-by: Eryu Guan <guaneryu@gmail.com>
# in the section name otherwise the section will not be resognised.
# Section name must be contained between square brackets.
get_config_sections() {
- sed -n -e "s/^\[\([[:alnum:]_]*\)\]/\1/p" < $1
+ sed -n -e "s/^\[\([[:alnum:]_-]*\)\]/\1/p" < $1
}
if [ ! -f "$HOST_OPTIONS" ]; then