]> git.ipfire.org Git - thirdparty/knot-resolver.git/commitdiff
lua worker.bg_worker: also report missing cqueues
authorVladimír Čunát <vladimir.cunat@nic.cz>
Tue, 14 Apr 2020 05:55:29 +0000 (07:55 +0200)
committerVladimír Čunát <vladimir.cunat@nic.cz>
Tue, 14 Apr 2020 07:17:23 +0000 (09:17 +0200)
Otherwise people could get confusing errors like:
> attempt to index field 'bg_worker' (a nil value)

daemon/lua/sandbox.lua.in

index 115bf5801fad914a3fce1894dafb42ed80306e2c..e5293d17b20fe7d029ca0cec41e19c07c82672f2 100644 (file)
@@ -638,4 +638,5 @@ else
        worker.sleep = disabled
        worker.map = disabled
        worker.coroutine = disabled
+       worker.bg_worker = setmetatable({}, { __index = disabled })
 end