Software /
code /
prosody
Changeset
12487:db634db8e069
net.server_select: Restore dependency on LuaSec to soft for tests
server_select is used in e.g. storagemanager tests, and some of the CI
runners are lacking LuaSec, which resulted in failures.
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Wed, 27 Apr 2022 21:45:36 +0200 |
parents | 12486:ee93df086926 |
children | 12490:1c5cb4c49c50 |
files | net/server_select.lua |
diffstat | 1 files changed, 1 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/net/server_select.lua Wed Apr 27 21:34:35 2022 +0200 +++ b/net/server_select.lua Wed Apr 27 21:45:36 2022 +0200 @@ -47,17 +47,15 @@ --// extern libs //-- -local has_luasec, luasec = pcall ( require , "ssl" ) local luasocket = use "socket" or require "socket" local luasocket_gettime = luasocket.gettime local inet = require "util.net"; local inet_pton = inet.pton; local sslconfig = require "util.sslconfig"; -local tls_impl = require "net.tls_luasec"; +local has_luasec, tls_impl = pcall(require, "net.tls_luasec"); --// extern lib methods //-- -local ssl_wrap = ( has_luasec and luasec.wrap ) local socket_bind = luasocket.bind local socket_select = luasocket.select