summaryrefslogtreecommitdiffstats
path: root/src/control.sh
diff options
context:
space:
mode:
authorPatrick McDermott <patrick.mcdermott@libiquity.com>2019-04-13 01:20:22 (EDT)
committer Patrick McDermott <patrick.mcdermott@libiquity.com>2019-04-13 01:20:22 (EDT)
commit58daff309a0b0c88bcf583ff971412667b88b83b (patch)
tree3309e60e8a1977a52427e6fe1508daf9cf128c17 /src/control.sh
parent7e1aa525daee8e9d32dd9e5da03a388284f0befe (diff)
parse_control(): Support any whitespace in field lists
Diffstat (limited to 'src/control.sh')
-rw-r--r--src/control.sh6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/control.sh b/src/control.sh
index 3950700..cec08ce 100644
--- a/src/control.sh
+++ b/src/control.sh
@@ -43,8 +43,8 @@ parse_control()
{
local file="${1}"
local field_cb="${2}"
- local req_fields=" ${3} "
- local opt_fields=" ${4} "
+ local req_fields="${3}"
+ local opt_fields="${4}"
shift 4
local got_fields=
local line_nr=
@@ -53,6 +53,8 @@ parse_control()
local value=
local sep=
+ req_fields=" $(printf '%s ' ${req_fields})"
+ opt_fields=" $(printf '%s ' ${opt_fields})"
got_fields=' '
line_nr=0