Skip to content

Commit 4eeb0de

Browse files
authored
Merge pull request #252 from laraPPr/clean_up_bash
Make cfg_files.sh more robut in bash environment
2 parents de1b4bb + c75a31a commit 4eeb0de

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

scripts/cfg_files.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,13 +39,13 @@ function cfg_load {
3939
local cur_val=""
4040
IFS=
4141
while read -r line; do
42-
new_section=$(cfg_get_section $line)
42+
new_section=$(cfg_get_section "${line}")
4343
# got a new section
4444
if [[ -n "$new_section" ]]; then
4545
cur_section=$new_section
4646
# not a section, try a key value
4747
else
48-
val=$(cfg_get_key_value $line)
48+
val=$(cfg_get_key_value "${line}")
4949
# trim leading and trailing spaces as well
5050
cur_key=$(echo $val | cut -f1 -d'=' | cfg_trim_spaces)
5151
cur_val=$(echo $val | cut -f2 -d'=' | cfg_trim_spaces)

0 commit comments

Comments
 (0)