changeset 31336:e9e41a04513d

merge of '5e579d58062410991f6268b66906fb7434730423' and '7eb555d9d20df94a7bef577253c8effb724ab484'
author ivan.komarov@soc.pidgin.im
date Tue, 02 Nov 2010 20:51:44 +0000
parents a2e2d351f6fb (current diff) 2d029c5cd305 (diff)
children 56e1f06471a9
files
diffstat 7 files changed, 28 insertions(+), 18 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Mon Nov 01 19:08:08 2010 +0000
+++ b/ChangeLog	Tue Nov 02 20:51:44 2010 +0000
@@ -2,15 +2,13 @@
 
 version 2.7.6 (??/??/????):
 	MSN:
-	* Added support for MSNP16:
-	* Added support for "Multi Points of Presence" (MPOP), which let users
-	  to sign on multiple places at the same time.
-	* Added extended capabilities support (no one implemented).
-	* Merged the work done on the Google SoC:
-	* A major rewrite of SLP code:
+	* Added support for MSNP16, including Multiple Points of Presence (MPOP)
+	  which allows multiple simultaneous sign-ins.
+	* Added extended capabilities support (none implemented).
+	* Merged the work done on the Google SoC (major rewrite of SLP code)
 	* Reworked the data transfer architecture.
 	  (http://developer.pidgin.im/wiki/SlpArchitecture)
-	* A lot of love to MSN prpl.
+	* Lots of little changes.
 
 version 2.7.5 (10/31/2010):
 	General:
--- a/libpurple/account.c	Mon Nov 01 19:08:08 2010 +0000
+++ b/libpurple/account.c	Tue Nov 02 20:51:44 2010 +0000
@@ -508,8 +508,6 @@
 		purple_account_remove_setting(account, "xferjp_host");
 
 	}
-
-	return;
 }
 
 static void
@@ -531,8 +529,6 @@
 		if(purple_strequal(tmp, "slogin.oscar.aol.com"))
 			purple_account_set_string(account, "server", "slogin.icq.com");
 	}
-
-	return;
 }
 
 static void
--- a/libpurple/protocols/jabber/adhoccommands.c	Mon Nov 01 19:08:08 2010 +0000
+++ b/libpurple/protocols/jabber/adhoccommands.c	Tue Nov 02 20:51:44 2010 +0000
@@ -125,7 +125,8 @@
 	xmlnode_set_attrib(command,"node",actionInfo->node);
 
 	/* cancel is handled differently on ad-hoc commands than regular forms */
-	if(!strcmp(xmlnode_get_namespace(result),"jabber:x:data") && !strcmp(xmlnode_get_attrib(result, "type"),"cancel")) {
+	if (purple_strequal(xmlnode_get_namespace(result), "jabber:x:data") &&
+			purple_strequal(xmlnode_get_attrib(result, "type"), "cancel")) {
 		xmlnode_set_attrib(command,"action","cancel");
 	} else {
 		if(actionhandle)
--- a/libpurple/protocols/jabber/auth.c	Mon Nov 01 19:08:08 2010 +0000
+++ b/libpurple/protocols/jabber/auth.c	Tue Nov 02 20:51:44 2010 +0000
@@ -502,20 +502,30 @@
 	return 0;
 }
 
+void jabber_auth_add_mech(JabberSaslMech *mech)
+{
+	auth_mechs = g_slist_insert_sorted(auth_mechs, mech, compare_mech);
+}
+
+void jabber_auth_remove_mech(JabberSaslMech *mech)
+{
+	auth_mechs = g_slist_remove(auth_mechs, mech);
+}
+
 void jabber_auth_init(void)
 {
 	JabberSaslMech **tmp;
 	gint count, i;
 
-	auth_mechs = g_slist_insert_sorted(auth_mechs, jabber_auth_get_plain_mech(), compare_mech);
-	auth_mechs = g_slist_insert_sorted(auth_mechs, jabber_auth_get_digest_md5_mech(), compare_mech);
+	jabber_auth_add_mech(jabber_auth_get_plain_mech());
+	jabber_auth_add_mech(jabber_auth_get_digest_md5_mech());
 #ifdef HAVE_CYRUS_SASL
-	auth_mechs = g_slist_insert_sorted(auth_mechs, jabber_auth_get_cyrus_mech(), compare_mech);
+	jabber_auth_add_mech(jabber_auth_get_cyrus_mech());
 #endif
 
 	tmp = jabber_auth_get_scram_mechs(&count);
 	for (i = 0; i < count; ++i)
-		auth_mechs = g_slist_insert_sorted(auth_mechs, tmp[i], compare_mech);
+		jabber_auth_add_mech(tmp[i]);
 }
 
 void jabber_auth_uninit(void)
--- a/libpurple/protocols/jabber/auth.h	Mon Nov 01 19:08:08 2010 +0000
+++ b/libpurple/protocols/jabber/auth.h	Tue Nov 02 20:51:44 2010 +0000
@@ -58,6 +58,9 @@
 JabberSaslMech *jabber_auth_get_cyrus_mech(void);
 #endif
 
+void jabber_auth_add_mech(JabberSaslMech *);
+void jabber_auth_remove_mech(JabberSaslMech *);
+
 void jabber_auth_init(void);
 void jabber_auth_uninit(void);
 
--- a/libpurple/protocols/jabber/presence.c	Mon Nov 01 19:08:08 2010 +0000
+++ b/libpurple/protocols/jabber/presence.c	Tue Nov 02 20:51:44 2010 +0000
@@ -995,12 +995,14 @@
 	}
 
 	for (child = packet->child; child; child = child->next) {
+		const char *xmlns;
 		char *key;
 		JabberPresenceHandler *pih;
 		if (child->type != XMLNODE_TYPE_TAG)
 			continue;
 
-		key = g_strdup_printf("%s %s", child->name, xmlnode_get_namespace(child));
+		xmlns = xmlnode_get_namespace(child);
+		key = g_strdup_printf("%s %s", child->name, xmlns ? xmlns : "");
 		pih = g_hash_table_lookup(presence_handlers, key);
 		g_free(key);
 		if (pih)
--- a/libpurple/protocols/oscar/oscar.c	Mon Nov 01 19:08:08 2010 +0000
+++ b/libpurple/protocols/oscar/oscar.c	Tue Nov 02 20:51:44 2010 +0000
@@ -621,7 +621,7 @@
 
 static const gchar *get_login_server(gboolean is_icq, gboolean use_ssl)
 {
-	return login_servers[is_icq*2 + use_ssl];
+	return login_servers[(is_icq ? 2 : 0) + (use_ssl ? 1 : 0)];
 }
 
 void