view util/xpcall.lua @ 10384:94c9c574cd8a 0.11

net.resolvers: Apply IDNA conversion to ascii for DNS lookups (fixes #1426)
author Kim Alvefur <zash@zash.se>
date Sat, 02 Nov 2019 19:24:26 +0100
parents cfc7b2f7251e
children d10957394a3c
line wrap: on
line source

local xpcall = xpcall;

if select(2, xpcall(function (x) return x end, function () end,  "test")) ~= "test" then
	xpcall = require"util.compat".xpcall;
end

return {
	xpcall = xpcall;
};