Software / code / prosody
File
util/adhoc.lua @ 10846:d0b098d0f6c3
net.server_epoll: Log some noise before TLS handshake step
This would help pinpoint if a crash happens during the handshake, which
has occurred a few times, e.g. like https://github.com/brunoos/luasec/issues/75
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Fri, 22 May 2020 15:20:19 +0200 |
| parent | 10667:49312378ba1d |
| child | 11352:e10567199f02 |
line wrap: on
line source
-- luacheck: ignore 212/self local function new_simple_form(form, result_handler) return function(self, data, state) if state or data.form then if data.action == "cancel" then return { status = "canceled" }; end local fields, err = form:data(data.form); return result_handler(fields, err, data); else return { status = "executing", actions = {"next", "complete", default = "complete"}, form = form }, "executing"; end end end local function new_initial_data_form(form, initial_data, result_handler) return function(self, data, state) if state or data.form then if data.action == "cancel" then return { status = "canceled" }; end local fields, err = form:data(data.form); return result_handler(fields, err, data); else return { status = "executing", actions = {"next", "complete", default = "complete"}, form = { layout = form, values = initial_data(data) } }, "executing"; end end end return { new_simple_form = new_simple_form, new_initial_data_form = new_initial_data_form };