summaryrefslogtreecommitdiff
path: root/tex/context/base/mkiv/file-lib.lua
diff options
context:
space:
mode:
Diffstat (limited to 'tex/context/base/mkiv/file-lib.lua')
-rw-r--r--tex/context/base/mkiv/file-lib.lua19
1 files changed, 12 insertions, 7 deletions
diff --git a/tex/context/base/mkiv/file-lib.lua b/tex/context/base/mkiv/file-lib.lua
index 62cf938ba..8ef1a48d3 100644
--- a/tex/context/base/mkiv/file-lib.lua
+++ b/tex/context/base/mkiv/file-lib.lua
@@ -61,13 +61,18 @@ function resolvers.uselibrary(specification) -- todo: reporter
if not foundname then
-- pattern based search
for i=1,#patterns do
- local wanted = format(patterns[i],barename)
- foundname = found(wanted)
- if trace_libraries then
- report_library("checking %a as %a: %s",filename,wanted,foundname or "not found")
- end
- if foundname then
- break
+ local pattern = patterns[i]
+ if pattern and pattern ~= "" then
+ local wanted = format(pattern,barename)
+ foundname = found(wanted)
+ if trace_libraries then
+ report_library("checking %a as %a: %s",filename,wanted,foundname or "not found")
+ end
+ if foundname then
+ break
+ end
+ else
+ -- can be a bogus path (coming from a test)
end
end
end