changeset 31832:73b005a20d06

Remove the _purple_oscar_convert(). It existed to migrate data from prpl-oscar to prpl-aim and prpl-icq. Fixes #2923
author Mark Doliner <mark@kingant.net>
date Thu, 17 Mar 2011 07:39:33 +0000
parents baa138225911
children 208c7d2ab4cd
files libpurple/account.c libpurple/blist.c libpurple/pounce.c libpurple/savedstatuses.c libpurple/util.c libpurple/util.h
diffstat 6 files changed, 1 insertions(+), 30 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/account.c	Thu Mar 17 01:42:14 2011 +0000
+++ b/libpurple/account.c	Thu Mar 17 07:39:33 2011 +0000
@@ -871,7 +871,7 @@
 		return NULL;
 	}
 
-	ret = purple_account_new(name, _purple_oscar_convert(name, protocol_id)); /* XXX: */
+	ret = purple_account_new(name, protocol_id);
 	g_free(name);
 	g_free(protocol_id);
 
--- a/libpurple/blist.c	Thu Mar 17 01:42:14 2011 +0000
+++ b/libpurple/blist.c	Thu Mar 17 07:39:33 2011 +0000
@@ -465,9 +465,7 @@
 
 	acct_name = xmlnode_get_attrib(bnode, "account");
 	protocol = xmlnode_get_attrib(bnode, "protocol");
-	protocol = _purple_oscar_convert(acct_name, protocol); /* XXX: Remove */
 	proto = xmlnode_get_attrib(bnode, "proto");
-	proto = _purple_oscar_convert(acct_name, proto); /* XXX: Remove */
 
 	if (!acct_name || (!proto && !protocol))
 		return;
--- a/libpurple/pounce.c	Thu Mar 17 01:42:14 2011 +0000
+++ b/libpurple/pounce.c	Thu Mar 17 07:39:33 2011 +0000
@@ -405,12 +405,8 @@
 	}
 
 	if (purple_strequal(element_name, "account")) {
-		char *tmp;
 		g_free(data->account_name);
 		data->account_name = g_strdup(buffer);
-		tmp = data->protocol_id;
-		data->protocol_id = g_strdup(_purple_oscar_convert(buffer, tmp));
-		g_free(tmp);
 	}
 	else if (purple_strequal(element_name, "pouncee")) {
 		g_free(data->pouncee);
--- a/libpurple/savedstatuses.c	Thu Mar 17 01:42:14 2011 +0000
+++ b/libpurple/savedstatuses.c	Thu Mar 17 07:39:33 2011 +0000
@@ -387,7 +387,6 @@
 		const char *protocol;
 		acct_name = xmlnode_get_data(node);
 		protocol = xmlnode_get_attrib(node, "protocol");
-		protocol = _purple_oscar_convert(acct_name, protocol); /* XXX: Remove */
 		if ((acct_name != NULL) && (protocol != NULL))
 			ret->account = purple_accounts_find(acct_name, protocol);
 		g_free(acct_name);
--- a/libpurple/util.c	Thu Mar 17 01:42:14 2011 +0000
+++ b/libpurple/util.c	Thu Mar 17 07:39:33 2011 +0000
@@ -4941,18 +4941,6 @@
 	return buf;
 }
 
-const char *_purple_oscar_convert(const char *act, const char *protocol)
-{
-	if (act && purple_strequal(protocol, "prpl-oscar")) {
-		int i;
-		for (i = 0; act[i] != '\0'; i++)
-			if (!isdigit(act[i]))
-				return "prpl-aim";
-		return "prpl-icq";
-	}
-	return protocol;
-}
-
 void purple_restore_default_signal_handlers(void)
 {
 #ifndef _WIN32
--- a/libpurple/util.h	Thu Mar 17 01:42:14 2011 +0000
+++ b/libpurple/util.h	Thu Mar 17 07:39:33 2011 +0000
@@ -1450,16 +1450,6 @@
 const char *purple_escape_filename(const char *str);
 
 /**
- * This is added temporarily to assist the split of oscar into aim and icq.
- * This should not be used by plugins.
- *
- * @deprecated This function should not be used in new code and should be
- *             removed in 3.0.0.  The aim/icq prpl split happened a long
- *             time ago, and we don't need to keep migrating old data.
- */
-const char *_purple_oscar_convert(const char *act, const char *protocol);
-
-/**
  * Restore default signal handlers for signals which might reasonably have
  * handlers. This should be called by a fork()'d child process, since child processes
  * inherit the handlers of the parent.