diff options
author | Hans Hagen <pragma@wxs.nl> | 2017-03-24 19:41:20 +0100 |
---|---|---|
committer | Context Git Mirror Bot <phg42.2a@gmail.com> | 2017-03-24 19:41:20 +0100 |
commit | dc54cea46e02502b4474a0fa132466974a9cc19c (patch) | |
tree | 403096f7ba8345b5dea1f925765523f7d52bd645 /tex/context/base/mkiv/util-sbx.lua | |
parent | 576286d4c1349c644bea833c99ec5364668ffc8a (diff) | |
download | context-dc54cea46e02502b4474a0fa132466974a9cc19c.tar.gz |
2017-03-24 19:13:00
Diffstat (limited to 'tex/context/base/mkiv/util-sbx.lua')
-rw-r--r-- | tex/context/base/mkiv/util-sbx.lua | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/tex/context/base/mkiv/util-sbx.lua b/tex/context/base/mkiv/util-sbx.lua index 0db2e0295..66a650875 100644 --- a/tex/context/base/mkiv/util-sbx.lua +++ b/tex/context/base/mkiv/util-sbx.lua @@ -369,6 +369,9 @@ local runners = { resultof = function(...) local command = validcommand(...) if command then + if trace then + report("resultof: %s",command) + end local handle = iopopen(command,"r") -- already has flush if handle then local result = handle:read("*all") or "" @@ -380,12 +383,18 @@ local runners = { execute = function(...) local command = validcommand(...) if command then + if trace then + report("execute: %s",command) + end return osexecute(command) end end, pipeto = function(...) local command = validcommand(...) if command then + if trace then + report("pipeto: %s",command) + end return iopopen(command,"w") -- already has flush end end, @@ -447,6 +456,10 @@ function sandbox.registerrunner(specification) end end +function sandbox.getrunner(name) + return name and validrunners[name] +end + local function suspicious(str) return (find(str,"[/\\]") or find(command,"%.%.")) and true or false end |