diff options
author | Philipp Gesang <phg42.2a@gmail.com> | 2014-07-12 21:14:37 +0200 |
---|---|---|
committer | Philipp Gesang <phg42.2a@gmail.com> | 2014-07-12 21:14:37 +0200 |
commit | 2668c9eb51bda60075c4c599d62bc8e31b25941b (patch) | |
tree | 44de70088a573a357947caf00604053bab304819 | |
parent | 9d92d615262ab0a2286146526db6b935f7a8c980 (diff) | |
download | luaotfload-2668c9eb51bda60075c4c599d62bc8e31b25941b.tar.gz |
[conf] allow spaces in formats specification
List items are now stripped of leading and trailing spaces before
building the formats list.
-rw-r--r-- | src/luaotfload-configuration.lua | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/luaotfload-configuration.lua b/src/luaotfload-configuration.lua index 937b050..3522bef 100644 --- a/src/luaotfload-configuration.lua +++ b/src/luaotfload-configuration.lua @@ -27,6 +27,7 @@ local luaotfloadstatus = require (status_file) local string = string local stringsub = string.sub local stringexplode = string.explode +local stringstrip = string.strip local table = table local tableappend = table.append @@ -278,7 +279,7 @@ local option_spec = { local known = { } local result = { } for i = 1, #fields do - local field = fields[i] + local field = stringstrip (fields[i]) if known[field] ~= true then --- yet unknown, tag as seen known[field] = true @@ -287,7 +288,8 @@ local option_spec = { result[#result + 1] = field else logreport ("both", 4, "conf", - "Invalid font format identifier %q, ignoring.", field) + "Invalid font format identifier %q, ignoring.", + field) end end end |