summaryrefslogtreecommitdiff
path: root/tex/context/base/mkiv/luat-cnf.lua
diff options
context:
space:
mode:
Diffstat (limited to 'tex/context/base/mkiv/luat-cnf.lua')
-rw-r--r--tex/context/base/mkiv/luat-cnf.lua21
1 files changed, 13 insertions, 8 deletions
diff --git a/tex/context/base/mkiv/luat-cnf.lua b/tex/context/base/mkiv/luat-cnf.lua
index 4f2c6569e..b6ee15083 100644
--- a/tex/context/base/mkiv/luat-cnf.lua
+++ b/tex/context/base/mkiv/luat-cnf.lua
@@ -19,7 +19,7 @@ texconfig.shell_escape = 't'
luatex = luatex or { }
local luatex = luatex
-texconfig.error_line = 79 -- frozen
+texconfig.error_line = 79 -- frozen / large values can crash
texconfig.expand_depth = 10000
texconfig.half_error_line = 50 -- frozen
texconfig.hash_extra = 100000
@@ -67,7 +67,7 @@ function texconfig.init()
"gzip", "zip", "zlib", "lfs", "ltn12", "mime", "socket", "md5", "fio", "unicode", "utf",
},
extratex = {
- "epdf", "fontloader", "kpse", "mplib",
+ "epdf", "kpse", "mplib", -- "fontloader",
},
obsolete = {
"fontloader", -- can be filled by luat-log
@@ -119,16 +119,21 @@ function texconfig.init()
-- shortcut and helper
- local bytecode = lua.bytecode
+ local setbytecode = lua.setbytecode
+ local getbytecode = lua.getbytecode
local function init(start)
local i = start
local t = os.clock()
- while bytecode[i] do
- bytecode[i]() ;
- bytecode[i] = nil ;
- i = i + 1
- -- collectgarbage('step')
+ while true do
+ local b = getbytecode(i)
+ if b then
+ b() ;
+ setbytecode(i,nil) ;
+ i = i + 1
+ else
+ break
+ end
end
return i - start, os.clock() - t
end