[asterisk-commits] res xmpp: Correctly check return value of SSL connect (asterisk[master])
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Fri Mar 24 09:13:07 CDT 2017
Anonymous Coward #1000019 has submitted this change and it was merged. ( https://gerrit.asterisk.org/5298 )
Change subject: res_xmpp: Correctly check return value of SSL_connect
......................................................................
res_xmpp: Correctly check return value of SSL_connect
SSL_connect returns non-zero for both success and some error conditions
so simply negating is inadequate.
Change-Id: Ifbf882896e598703b6c615407fa456d3199f95b1
---
M res/res_xmpp.c
1 file changed, 1 insertion(+), 1 deletion(-)
Approvals:
Kevin Harwell: Looks good to me, but someone else must approve
Anonymous Coward #1000019: Verified
Joshua Colp: Looks good to me, approved
diff --git a/res/res_xmpp.c b/res/res_xmpp.c
index 1aa865c..ddd4a57 100644
--- a/res/res_xmpp.c
+++ b/res/res_xmpp.c
@@ -2670,7 +2670,7 @@
goto failure;
}
- if (!SSL_connect(client->ssl_session)) {
+ if (SSL_connect(client->ssl_session) <= 0) {
goto failure;
}
--
To view, visit https://gerrit.asterisk.org/5298
To unsubscribe, visit https://gerrit.asterisk.org/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Ifbf882896e598703b6c615407fa456d3199f95b1
Gerrit-PatchSet: 1
Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Owner: Sean Bright <sean.bright at gmail.com>
Gerrit-Reviewer: Anonymous Coward #1000019
Gerrit-Reviewer: Joshua Colp <jcolp at digium.com>
Gerrit-Reviewer: Kevin Harwell <kharwell at digium.com>
More information about the asterisk-commits
mailing list