From 4ccffd85ffd06325687546f78b78e3e7fce575c5 Mon Sep 17 00:00:00 2001 From: LemonBoy Date: Thu, 20 Oct 2016 21:41:36 +0200 Subject: Expose 'sasl_success' to the perl side. --- src/fe-common/irc/fe-sasl.c | 2 +- src/perl/irc/Irc.xs | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/fe-common/irc/fe-sasl.c b/src/fe-common/irc/fe-sasl.c index dfbfc84a..4c86f850 100644 --- a/src/fe-common/irc/fe-sasl.c +++ b/src/fe-common/irc/fe-sasl.c @@ -42,7 +42,7 @@ static void sig_cap_end(IRC_SERVER_REC *server) { /* The negotiation has now been terminated, if we didn't manage to * authenticate successfully with the server just disconnect. */ - if (server->sasl_success == FALSE && + if (!server->sasl_success && settings_get_bool("sasl_disconnect_on_failure")) server_disconnect(SERVER(server)); diff --git a/src/perl/irc/Irc.xs b/src/perl/irc/Irc.xs index 8b3b0c45..41690010 100644 --- a/src/perl/irc/Irc.xs +++ b/src/perl/irc/Irc.xs @@ -32,6 +32,7 @@ static void perl_irc_server_fill_hash(HV *hv, IRC_SERVER_REC *server) (void) hv_store(hv, "isupport_sent", 13, newSViv(server->isupport_sent), 0); (void) hv_store(hv, "cap_complete", 12, newSViv(server->cap_complete), 0); + (void) hv_store(hv, "sasl_success", 12, newSViv(server->sasl_success), 0); av = newAV(); for (tmp = server->cap_supported; tmp != NULL; tmp = tmp->next) -- cgit v1.2.3