Software /
code /
prosody
Changeset
2404:d7abdd6893b8
util.sasl_cyrus: Report an error if Cyrus SASL init fails.
author | Tobias Markmann <tm@ayena.de> |
---|---|
date | Wed, 30 Dec 2009 16:43:08 +0100 |
parents | 2403:916482cdfb74 |
children | 2405:88f73ee1c46f |
files | util/sasl_cyrus.lua |
diffstat | 1 files changed, 4 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/util/sasl_cyrus.lua Tue Dec 29 01:04:48 2009 +0100 +++ b/util/sasl_cyrus.lua Wed Dec 30 16:43:08 2009 +0100 @@ -35,8 +35,11 @@ local function init(service_name) if not initialized then - if pcall(cyrussasl.server_init, service_name) then + local st, errmsg = pcall(cyrussasl.server_init, service_name); + if st then initialized = true; + else + log("error", "Failed to initialize CyrusSASL: %s", errmsg); end end end