From 0c75a2acf592eb4360685375904440f5e6b8125a Mon Sep 17 00:00:00 2001 From: Hans Hagen Date: Tue, 12 Nov 2019 19:54:50 +0100 Subject: 2019-11-12 18:53:00 --- tex/context/base/mkiv/data-res.lua | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'tex/context/base/mkiv/data-res.lua') diff --git a/tex/context/base/mkiv/data-res.lua b/tex/context/base/mkiv/data-res.lua index f3b76778f..15d9f3db9 100644 --- a/tex/context/base/mkiv/data-res.lua +++ b/tex/context/base/mkiv/data-res.lua @@ -1839,10 +1839,10 @@ function resolvers.dowithvariable(name,func) end function resolvers.locateformat(name) - local engine = environment.ownmain or "luatex" - local barename = removesuffix(name) + local engine = environment.ownmain or "luatex" + local barename = removesuffix(file.basename(name)) local fullname = addsuffix(barename,"fmt") - local fmtname = caches.getfirstreadablefile(fullname,"formats",engine) or "" + local fmtname = caches.getfirstreadablefile(fullname,"formats",engine) or "" if fmtname == "" then fmtname = resolvers.findfile(fullname) fmtname = cleanpath(fmtname) @@ -1853,11 +1853,11 @@ function resolvers.locateformat(name) local lucname = addsuffix(barename,luasuffixes.luc) local luiname = addsuffix(barename,luasuffixes.lui) if isfile(luiname) then - return barename, luiname + return fmtname, luiname elseif isfile(lucname) then - return barename, lucname + return fmtname, lucname elseif isfile(luaname) then - return barename, luaname + return fmtname, luaname end end return nil, nil -- cgit v1.2.3