im.pidgin.pidgin: c6cea9233a5f4d22b6b5f012bd8432d2732765ea

datallah at pidgin.im datallah at pidgin.im
Sun Nov 25 15:55:42 EST 2007


-----------------------------------------------------------------
Revision: c6cea9233a5f4d22b6b5f012bd8432d2732765ea
Ancestor: 9ef9ba3a227b9674b206f6c47361a9d138a22869
Author: datallah at pidgin.im
Date: 2007-11-25T20:51:25
Branch: im.pidgin.pidgin

Modified files:
        libpurple/protocols/jabber/libxmpp.c
        libpurple/protocols/jabber/si.c

ChangeLog: 

Now that the release has been tagged and strings are unfrozen, enable the new ft proxy account setting for xmpp accounts. Also, prevent duplicate entries in the streamhost lists.  I don't know if the default account proxy is acceptable, perhaps there shouldn't be a default value.

-------------- next part --------------
============================================================
--- libpurple/protocols/jabber/libxmpp.c	e90c78b600e55ee816eae95ffc4c0fd69fdd785b
+++ libpurple/protocols/jabber/libxmpp.c	52de35f001f19da22d32b4cae3204ec0c20538e1
@@ -219,33 +219,31 @@ init_plugin(PurplePlugin *plugin)
 											   option);
 	
 	option = purple_account_option_bool_new(
-											_("Allow plaintext auth over unencrypted streams"),
-											"auth_plain_in_clear", FALSE);
+						_("Allow plaintext auth over unencrypted streams"),
+						"auth_plain_in_clear", FALSE);
 	prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
-											   option);
-	
+						   option);
+
 	option = purple_account_option_int_new(_("Connect port"), "port", 5222);
 	prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
-											   option);
-	
+						   option);
+
 	option = purple_account_option_string_new(_("Connect server"),
-											  "connect_server", NULL);
+						  "connect_server", NULL);
 	prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
-											   option);
-	
-#if 0 /* TODO: Enable this when we're string unfrozen */
+						  option);
+
 	option = purple_account_option_string_new(_("File transfer proxies"),
 						  "ft_proxies",
 						/* TODO: Is this an acceptable default? */
 						  "proxy.jabber.org:7777");
 	prpl_info.protocol_options = g_list_append(prpl_info.protocol_options,
 						  option);
-#endif
 
 	jabber_init_plugin(plugin);
-	
+
 	purple_prefs_remove("/plugins/prpl/jabber");
-	
+
 	/* XXX - If any other plugin wants SASL this won't be good ... */
 #ifdef HAVE_CYRUS_SASL
 #ifdef _WIN32
============================================================
--- libpurple/protocols/jabber/si.c	0addee72648bfa16a97fb3a8d326e11b675cff9d
+++ libpurple/protocols/jabber/si.c	d8b734d2935d85ed8676012a241acb9c5a2321db
@@ -780,6 +780,9 @@ jabber_si_xfer_bytestreams_listen_cb(int
 
 			g_snprintf(port, sizeof(port), "%hu", portnum);
 
+			if(g_list_find_custom(jsx->streamhosts, ft_proxy_list[i], jabber_si_compare_jid) != NULL)
+				continue;
+
 			streamhost = xmlnode_new_child(query, "streamhost");
 			xmlnode_set_attrib(streamhost, "jid", ft_proxy_list[i]);
 			xmlnode_set_attrib(streamhost, "host", ft_proxy_list[i]);
@@ -801,9 +804,12 @@ jabber_si_xfer_bytestreams_listen_cb(int
 
 		/* TODO: deal with zeroconf proxies */
 
-		if (!(sh->host && sh->port > 0))
+		if (!(sh->jid && sh->host && sh->port > 0))
 			continue;
 
+		if(g_list_find_custom(jsx->streamhosts, sh->jid, jabber_si_compare_jid) != NULL)
+			continue;
+
 		streamhost = xmlnode_new_child(query, "streamhost");
 		xmlnode_set_attrib(streamhost, "jid", sh->jid);
 		xmlnode_set_attrib(streamhost, "host", sh->host);


More information about the Commits mailing list