aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2022-05-16 14:51:58 +0200
committerKim Alvefur <zash@zash.se>2022-05-16 14:51:58 +0200
commit11017d1130b99b5d0979cf8393ebc2446bea82af (patch)
tree406b77497c28aaaf0f418d3c36f929ea8f04fe20 /net
parentbd9db0ee1a39d1d2cf2476f51b44c5beaf5fa443 (diff)
parent24288146ae05b47d74bd0d4403825048593623d9 (diff)
downloadprosody-11017d1130b99b5d0979cf8393ebc2446bea82af.tar.gz
prosody-11017d1130b99b5d0979cf8393ebc2446bea82af.zip
Merge 0.12->trunk
Diffstat (limited to 'net')
-rw-r--r--net/unbound.lua11
1 files changed, 10 insertions, 1 deletions
diff --git a/net/unbound.lua b/net/unbound.lua
index 4a6f0241..4d8f9284 100644
--- a/net/unbound.lua
+++ b/net/unbound.lua
@@ -25,13 +25,22 @@ local dns_utils = require"util.dns";
local classes, types, errors = dns_utils.classes, dns_utils.types, dns_utils.errors;
local parsers = dns_utils.parsers;
+local builtin_defaults = { hoststxt = false }
+
local function add_defaults(conf)
if conf then
+ for option, default in pairs(builtin_defaults) do
+ if conf[option] == nil then
+ conf[option] = default;
+ end
+ end
for option, default in pairs(libunbound.config) do
if conf[option] == nil then
conf[option] = default;
end
end
+ else
+ return builtin_defaults;
end
return conf;
end
@@ -133,7 +142,7 @@ local function lookup(callback, qname, qtype, qclass)
if ret then
waiting_queries[ret] = callback;
else
- log_query("warn", "Resolver error: %s", err);
+ log_query("error", "Resolver error: %s", err);
end
return ret, err;
end