pidgin: fe36f3cc: jabber: Handle a corner case better by t...
darkrain42 at pidgin.im
darkrain42 at pidgin.im
Wed Oct 13 23:15:51 EDT 2010
----------------------------------------------------------------------
Revision: fe36f3cc103e9f3e86937ec01f11257123b961fc
Parent: 4ecff991551af44864df272b9d778f4eb2d7bf27
Author: darkrain42 at pidgin.im
Date: 10/13/10 23:12:01
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/fe36f3cc103e9f3e86937ec01f11257123b961fc
Changelog:
jabber: Handle a corner case better by throwing an error instead of stalling
This happens if the server *has* a TXT record for _xmppconnect.$domain,
but has no useful content there. Fixes #12744, #a14367.
Changes against parent 4ecff991551af44864df272b9d778f4eb2d7bf27
patched ChangeLog
patched libpurple/protocols/jabber/jabber.c
-------------- next part --------------
============================================================
--- ChangeLog 1eab4e0833907bb40798c5437a2e76ac63266d48
+++ ChangeLog f0ec1544a47b99dfc260d2bc05a5c8a2b16f89d6
@@ -60,6 +60,9 @@ version 2.7.4 (MM/DD/YYYY):
for Your Domain). (#a14153)
* Improved handling of adding oneself to your buddy list when using
Non-SASL (legacy) authentication. (#12499)
+ * Generate a connection error instead of just stalling when the
+ _xmppconnect TXT record returns results, but none of them result
+ in a valid BOSH URI. (#a14367, #12744)
Yahoo/Yahoo JAPAN:
* Stop doing unnecessary lookups of certain alias information. This
============================================================
--- libpurple/protocols/jabber/jabber.c 860ec35a972760253c78446914280947d58716f1
+++ libpurple/protocols/jabber/jabber.c 64d5e423fb0f05e8949de6bb3bd43019edd171f2
@@ -762,18 +762,10 @@ txt_resolved_cb(GList *responses, gpoint
txt_resolved_cb(GList *responses, gpointer data)
{
JabberStream *js = data;
+ gboolean found = FALSE;
js->srv_query_data = NULL;
- if (responses == NULL) {
- purple_debug_warning("jabber", "Unable to find alternative XMPP connection "
- "methods after failing to connect directly.\n");
- purple_connection_error_reason(js->gc,
- PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
- _("Unable to connect"));
- return;
- }
-
while (responses) {
PurpleTxtResponse *resp = responses->data;
gchar **token;
@@ -790,11 +782,19 @@ txt_resolved_cb(GList *responses, gpoint
}
if (js->bosh) {
+ found = TRUE;
jabber_bosh_connection_connect(js->bosh);
- } else {
- purple_debug_info("jabber","Didn't find an alternative connection method.\n");
}
+ if (!found) {
+ purple_debug_warning("jabber", "Unable to find alternative XMPP connection "
+ "methods after failing to connect directly.\n");
+ purple_connection_error_reason(js->gc,
+ PURPLE_CONNECTION_ERROR_NETWORK_ERROR,
+ _("Unable to connect"));
+ return;
+ }
+
if (responses) {
g_list_foreach(responses, (GFunc)purple_txt_response_destroy, NULL);
g_list_free(responses);
More information about the Commits
mailing list