]> git.ipfire.org Git - thirdparty/knot-resolver.git/commitdiff
lua log(): make it work again
authorVladimír Čunát <vladimir.cunat@nic.cz>
Wed, 3 Nov 2021 16:44:36 +0000 (17:44 +0100)
committerVladimír Čunát <vladimir.cunat@nic.cz>
Thu, 4 Nov 2021 09:31:31 +0000 (10:31 +0100)
sandbox.lua:72: attempt to call global 'log_notice' (a nil value)
Broken by commit 39dd89db (MR !1208)

NEWS
daemon/lua/sandbox.lua.in

diff --git a/NEWS b/NEWS
index e6bc4a35ec57cc67c931f436a889df44c130ec3f..30bd1aa35719a6090a2dca9d3f55d150bf844964 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -4,6 +4,7 @@ Knot Resolver 5.4.3 (2021-mm-dd)
 Bugfixes
 --------
 - policy.rpz: improve logs, fix origin detection in files without $ORIGIN
+- lua: log() works again; broken in 5.4.2 (!1223)
 
 
 Knot Resolver 5.4.2 (2021-10-13)
index cd9ec25b6f091702e17e42b33c19a35e5c1c35c4..35eafa1306b2a6031bb0cf7e5c83f38a84e67897 100644 (file)
@@ -60,6 +60,10 @@ function log_warn(grp, fmt, ...)
        log_fmt(grp, LOG_WARNING, fmt, ...)
 end
 
+function log_notice(grp, fmt, ...)
+       log_fmt(grp, LOG_NOTICE, fmt, ...)
+end
+
 function log_info(grp, fmt, ...)
        log_fmt(grp, LOG_INFO, fmt, ...)
 end