changeset 30430:351d07aefb09

Kill off many dead assignments and any useless remaining variables. I think some of those QQ ones were actual logic errors, too. Let me know if there were any side-effects that were cut.
author Elliott Sales de Andrade <qulogic@pidgin.im>
date Mon, 23 Aug 2010 00:52:24 +0000
parents 922c8c553758
children c9a57878ed17
files finch/gntft.c finch/libgnt/gntentry.c libpurple/conversation.c libpurple/media/backend-fs2.c libpurple/plugins/idle.c libpurple/prefs.c libpurple/protocols/bonjour/bonjour.c libpurple/protocols/jabber/jingle/transport.c libpurple/protocols/jabber/roster.c libpurple/protocols/jabber/si.c libpurple/protocols/msn/contact.c libpurple/protocols/msn/httpconn.c libpurple/protocols/msn/msn.c libpurple/protocols/msn/notification.c libpurple/protocols/msn/slp.c libpurple/protocols/msn/switchboard.c libpurple/protocols/qq/buddy_info.c libpurple/protocols/qq/buddy_list.c libpurple/protocols/qq/buddy_opt.c libpurple/protocols/qq/file_trans.c libpurple/protocols/qq/group.c libpurple/protocols/qq/group_im.c libpurple/protocols/qq/group_join.c libpurple/protocols/qq/group_opt.c libpurple/protocols/qq/im.c libpurple/protocols/qq/qq.c libpurple/protocols/qq/qq_base.c libpurple/protocols/qq/qq_network.c libpurple/protocols/qq/qq_process.c libpurple/protocols/qq/qq_trans.c libpurple/protocols/qq/send_file.c libpurple/protocols/yahoo/libymsg.c libpurple/protocols/yahoo/yahoo_filexfer.c libpurple/protocols/yahoo/yahoochat.c pidgin/gtkblist.c pidgin/gtkconv.c pidgin/gtkdialogs.c pidgin/gtkft.c pidgin/gtkimhtml.c pidgin/gtkimhtmltoolbar.c pidgin/gtkpounce.c pidgin/gtkroomlist.c pidgin/gtksmiley.c pidgin/gtkstatusbox.c pidgin/gtkutils.c pidgin/plugins/notify.c
diffstat 46 files changed, 62 insertions(+), 350 deletions(-) [+]
line wrap: on
line diff
--- a/finch/gntft.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/finch/gntft.c	Mon Aug 23 00:52:24 2010 +0000
@@ -383,8 +383,6 @@
 		return;
 	}
 
-	data = FINCHXFER(xfer);
-
 	update_title_progress();
 
 	if (purple_xfer_is_canceled(xfer))
@@ -402,7 +400,7 @@
 	char *size_str, *remaining_str;
 	time_t current_time;
 	char prog_str[5];
-	double kb_sent, kb_rem;
+	double kb_sent;
 	double kbps = 0.0;
 	time_t elapsed, now;
 	char *kbsec;
@@ -412,7 +410,6 @@
 		now = time(NULL);
 
 	kb_sent = purple_xfer_get_bytes_sent(xfer) / 1024.0;
-	kb_rem  = purple_xfer_get_bytes_remaining(xfer) / 1024.0;
 	elapsed = (purple_xfer_get_start_time(xfer) > 0 ? now - purple_xfer_get_start_time(xfer) : 0);
 	kbps    = (elapsed > 0 ? (kb_sent / elapsed) : 0);
 
--- a/finch/libgnt/gntentry.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/finch/libgnt/gntentry.c	Mon Aug 23 00:52:24 2010 +0000
@@ -481,7 +481,6 @@
 	GntEntry *entry = GNT_ENTRY(bind);
 	GList *iter;
 	const char *current;
-	int len;
 	
 	if (entry->history->prev && entry->search->needle)
 		current = entry->search->needle;
@@ -491,8 +490,6 @@
 	if (!entry->histlength || !entry->history->next || !*current)
 		return FALSE;
 
-	len = g_utf8_strlen(current, -1);
-
 	for (iter = entry->history->next; iter; iter = iter->next) {
 		const char *str = iter->data;
 		/* A more utf8-friendly version of strstr would have been better, but
--- a/libpurple/conversation.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/conversation.c	Mon Aug 23 00:52:24 2010 +0000
@@ -1124,7 +1124,6 @@
 purple_conv_im_start_typing_timeout(PurpleConvIm *im, int timeout)
 {
 	PurpleConversation *conv;
-	const char *name;
 
 	g_return_if_fail(im != NULL);
 
@@ -1132,7 +1131,6 @@
 		purple_conv_im_stop_typing_timeout(im);
 
 	conv = purple_conv_im_get_conversation(im);
-	name = purple_conversation_get_name(conv);
 
 	im->typing_timeout = purple_timeout_add_seconds(timeout, reset_typing_cb, conv);
 }
@@ -1520,7 +1518,6 @@
 	PurpleAccount *account;
 	PurpleConversation *conv;
 	PurpleConnection *gc;
-	PurplePluginProtocolInfo *prpl_info;
 
 	g_return_if_fail(chat != NULL);
 	g_return_if_fail(who != NULL);
@@ -1529,7 +1526,6 @@
 	conv      = purple_conv_chat_get_conversation(chat);
 	gc        = purple_conversation_get_gc(conv);
 	account   = purple_connection_get_account(gc);
-	prpl_info = PURPLE_PLUGIN_PROTOCOL_INFO(purple_connection_get_prpl(gc));
 
 	/* Don't display this if the person who wrote it is ignored. */
 	if (purple_conv_chat_is_user_ignored(chat, who))
--- a/libpurple/media/backend-fs2.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/media/backend-fs2.c	Mon Aug 23 00:52:24 2010 +0000
@@ -1837,15 +1837,12 @@
 purple_media_backend_fs2_get_codecs(PurpleMediaBackend *self,
 		const gchar *sess_id)
 {
-	PurpleMediaBackendFs2Private *priv;
 	PurpleMediaBackendFs2Session *session;
 	GList *fscodecs;
 	GList *codecs;
 
 	g_return_val_if_fail(PURPLE_IS_MEDIA_BACKEND_FS2(self), NULL);
 
-	priv = PURPLE_MEDIA_BACKEND_FS2_GET_PRIVATE(self);
-
 	session = get_session(PURPLE_MEDIA_BACKEND_FS2(self), sess_id);
 
 	if (session == NULL)
@@ -2014,13 +2011,10 @@
 		const gchar *sess_id, const gchar *who, double level)
 {
 #ifdef USE_VV
-	PurpleMediaBackendFs2Private *priv;
 	GList *streams;
 
 	g_return_if_fail(PURPLE_IS_MEDIA_BACKEND_FS2(self));
 
-	priv = PURPLE_MEDIA_BACKEND_FS2_GET_PRIVATE(self);
-
 	purple_prefs_set_int("/purple/media/audio/volume/output", level);
 
 	streams = get_streams(self, sess_id, who);
--- a/libpurple/plugins/idle.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/plugins/idle.c	Mon Aug 23 00:52:24 2010 +0000
@@ -110,9 +110,6 @@
 	for(iter = list; iter; iter = iter->next) {
 		acct = (PurpleAccount *)(iter->data);
 
-		if(acct)
-			prpl_id = purple_account_get_protocol_id(acct);
-
 		if(acct && idleable_filter(acct)) {
 			purple_debug_misc("idle", "Idling %s.\n",
 					purple_account_get_username(acct));
--- a/libpurple/prefs.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/prefs.c	Mon Aug 23 00:52:24 2010 +0000
@@ -506,7 +506,6 @@
 		return g_strdup("/");
 
 	name = g_string_new(pref->name);
-	parent = pref->parent;
 
 	for(parent = pref->parent; parent && parent->name; parent = parent->parent) {
 		name = g_string_prepend_c(name, '/');
--- a/libpurple/protocols/bonjour/bonjour.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/bonjour/bonjour.c	Mon Aug 23 00:52:24 2010 +0000
@@ -206,18 +206,12 @@
 {
 	PurpleConnection *gc;
 	BonjourData *bd;
-	gboolean disconnected;
-	PurpleStatusType *type;
-	int primitive;
 	PurplePresence *presence;
 	const char *message, *bonjour_status;
 	gchar *stripped;
 
 	gc = purple_account_get_connection(account);
 	bd = gc->proto_data;
-	disconnected = purple_account_is_disconnected(account);
-	type = purple_status_get_type(status);
-	primitive = purple_status_type_get_primitive(type);
 	presence = purple_account_get_presence(account);
 
 	message = purple_status_get_attr_string(status, "message");
--- a/libpurple/protocols/jabber/jingle/transport.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/jabber/jingle/transport.c	Mon Aug 23 00:52:24 2010 +0000
@@ -111,8 +111,6 @@
 	JingleTransport *transport;
 	g_return_if_fail(JINGLE_IS_TRANSPORT(object));
 
-	transport = JINGLE_TRANSPORT(object);
-
 	switch (prop_id) {
 		default:	
 			G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
@@ -125,8 +123,6 @@
 {
 	JingleTransport *transport;
 	g_return_if_fail(JINGLE_IS_TRANSPORT(object));
-	
-	transport = JINGLE_TRANSPORT(object);
 
 	switch (prop_id) {
 		default:	
--- a/libpurple/protocols/jabber/roster.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/jabber/roster.c	Mon Aug 23 00:52:24 2010 +0000
@@ -76,12 +76,9 @@
 
 void jabber_roster_request(JabberStream *js)
 {
-	PurpleAccount *account;
 	JabberIq *iq;
 	xmlnode *query;
 
-	account = purple_connection_get_account(js->gc);
-
 	iq = jabber_iq_new_query(js, JABBER_IQ_GET, "jabber:iq:roster");
 	query = xmlnode_get_child(iq->node, "query");
 
--- a/libpurple/protocols/jabber/si.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/jabber/si.c	Mon Aug 23 00:52:24 2010 +0000
@@ -1666,12 +1666,8 @@
 
 void jabber_si_xfer_send(PurpleConnection *gc, const char *who, const char *file)
 {
-	JabberStream *js;
-
 	PurpleXfer *xfer;
 
-	js = gc->proto_data;
-
 	xfer = jabber_si_new_xfer(gc, who);
 
 	if (file)
--- a/libpurple/protocols/msn/contact.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/msn/contact.c	Mon Aug 23 00:52:24 2010 +0000
@@ -527,16 +527,20 @@
 	g_return_if_fail(session != NULL);
 
 	if (resp != NULL) {
+#ifdef MSN_PARTIAL_LISTS
 		const char *abLastChange;
 		const char *dynamicItemLastChange;
+#endif
 
 		purple_debug_misc("msn", "Got the contact list!\n");
 
 		msn_parse_contact_list(session, resp->xml);
+#ifdef MSN_PARTIAL_LISTS
 		abLastChange = purple_account_get_string(session->account,
 			"ablastChange", NULL);
 		dynamicItemLastChange = purple_account_get_string(session->account,
 			"DynamicItemLastChanged", NULL);
+#endif
 
 		if (state->partner_scenario == MSN_PS_INITIAL) {
 #ifdef MSN_PARTIAL_LISTS
--- a/libpurple/protocols/msn/httpconn.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/msn/httpconn.c	Mon Aug 23 00:52:24 2010 +0000
@@ -239,6 +239,9 @@
 		}
 		else
 		{
+			/* I'll be honest, I don't fully understand all this, but this
+			 * causes crashes, Stu. */
+#if 0
 			MsnServConn *servconn;
 
 			/* It's going to die. */
@@ -246,10 +249,9 @@
 
 			servconn = httpconn->servconn;
 
-			/* I'll be honest, I don't fully understand all this, but this
-			 * causes crashes, Stu. */
-			/* if (servconn != NULL)
-				servconn->wasted = TRUE; */
+			if (servconn != NULL)
+				servconn->wasted = TRUE;
+#endif
 
 			g_free(full_session_id);
 			g_free(session_id);
--- a/libpurple/protocols/msn/msn.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/msn/msn.c	Mon Aug 23 00:52:24 2010 +0000
@@ -622,7 +622,6 @@
 {
 	PurpleBuddy *buddy;
 	PurpleConnection *gc;
-	MsnSession *session;
 	MsnMobileData *data;
 	PurpleAccount *account;
 	const char *name;
@@ -634,8 +633,6 @@
 	gc = purple_account_get_connection(account);
 	name = purple_buddy_get_name(buddy);
 
-	session = gc->proto_data;
-
 	data = g_new0(MsnMobileData, 1);
 	data->gc = gc;
 	data->passport = name;
@@ -2084,11 +2081,9 @@
 msn_remove_group(PurpleConnection *gc, PurpleGroup *group)
 {
 	MsnSession *session;
-	MsnCmdProc *cmdproc;
 	const char *gname;
 
 	session = gc->proto_data;
-	cmdproc = session->notification->cmdproc;
 	gname = purple_group_get_name(group);
 
 	purple_debug_info("msn", "Remove group %s\n", gname);
--- a/libpurple/protocols/msn/notification.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/msn/notification.c	Mon Aug 23 00:52:24 2010 +0000
@@ -92,7 +92,6 @@
 {
 	MsnCmdProc *cmdproc;
 	MsnSession *session;
-	PurpleAccount *account;
 	GString *vers;
 	const char *ver_str;
 	int i;
@@ -101,7 +100,6 @@
 
 	cmdproc = servconn->cmdproc;
 	session = servconn->session;
-	account = session->account;
 
 	vers = g_string_new("");
 
@@ -178,10 +176,8 @@
 usr_cmd(MsnCmdProc *cmdproc, MsnCommand *cmd)
 {
 	MsnSession *session;
-	PurpleAccount *account;
 
 	session = cmdproc->session;
-	account = session->account;
 
 	if (!g_ascii_strcasecmp(cmd->params[1], "OK"))
 	{
@@ -1000,7 +996,6 @@
 {
 	MsnSession *session;
 	PurpleAccount *account;
-	PurpleConnection *gc;
 	MsnUser *user;
 	MsnObject *msnobj = NULL;
 	unsigned long clientid;
@@ -1010,7 +1005,6 @@
 
 	session = cmdproc->session;
 	account = session->account;
-	gc = purple_account_get_connection(account);
 
 	state    = cmd->params[1];
 	passport = cmd->params[2];
@@ -1203,7 +1197,6 @@
 {
 	MsnSession *session;
 	PurpleAccount *account;
-	PurpleConnection *gc;
 	MsnUser *user;
 	MsnObject *msnobj;
 	unsigned long clientid;
@@ -1212,7 +1205,6 @@
 
 	session = cmdproc->session;
 	account = session->account;
-	gc = purple_account_get_connection(account);
 
 	state    = cmd->params[0];
 	passport = cmd->params[1];
@@ -1387,11 +1379,13 @@
 	MsnSession *session;
 	MsnSwitchBoard *swboard;
 	const char *session_id;
+	const char *auth_key;
 	char *host;
 	int port;
 
 	session = cmdproc->session;
 	session_id = cmd->params[0];
+	auth_key = cmd->params[3];
 
 	msn_parse_socket(cmd->params[1], &host, &port);
 
@@ -1401,8 +1395,8 @@
 	swboard = msn_switchboard_new(session);
 
 	msn_switchboard_set_invited(swboard, TRUE);
-	msn_switchboard_set_session_id(swboard, cmd->params[0]);
-	msn_switchboard_set_auth_key(swboard, cmd->params[3]);
+	msn_switchboard_set_session_id(swboard, session_id);
+	msn_switchboard_set_auth_key(swboard, auth_key);
 	swboard->im_user = g_strdup(cmd->params[4]);
 	/* msn_switchboard_add_user(swboard, cmd->params[4]); */
 
@@ -1571,13 +1565,11 @@
 			 size_t len)
 {
 	MsnSession *session;
-	PurpleAccount *account;
 	MsnUser *user;
 	const char *passport;
 	char *str;
 
 	session = cmdproc->session;
-	account = session->account;
 
 	passport = cmd->params[0];
 	user = msn_userlist_find_user(session->userlist, passport);
@@ -1649,7 +1641,9 @@
 {
 	MsnSession *session;
 	const char *value;
+#ifdef MSN_PARTIAL_LISTS
 	const char *clLastChange;
+#endif
 
 	session = cmdproc->session;
 
@@ -1692,9 +1686,9 @@
 	if ((value = msn_message_get_attr(msg, "EmailEnabled")) != NULL)
 		session->passport_info.email_enabled = (gboolean)atol(value);
 
+#ifdef MSN_PARTIAL_LISTS
 	/*starting retrieve the contact list*/
 	clLastChange = purple_account_get_string(session->account, "CLLastChange", NULL);
-#ifdef MSN_PARTIAL_LISTS
 	/* msn_userlist_load defeats all attempts at trying to detect blist sync issues */
 	msn_userlist_load(session);
 	msn_get_contact_list(session, MSN_PS_INITIAL, clLastChange);
--- a/libpurple/protocols/msn/slp.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/msn/slp.c	Mon Aug 23 00:52:24 2010 +0000
@@ -1263,8 +1263,6 @@
 	if (userlist->buddy_icon_window > 0)
 	{
 		GQueue *queue;
-		PurpleAccount *account;
-		const char *username;
 
 		queue = userlist->buddy_icon_requests;
 
@@ -1273,9 +1271,6 @@
 
 		user = g_queue_pop_head(queue);
 
-		account  = userlist->session->account;
-		username = user->passport;
-
 		userlist->buddy_icon_window--;
 		request_user_display(user);
 
@@ -1347,31 +1342,21 @@
 got_user_display(MsnSlpCall *slpcall,
 				 const guchar *data, gsize size)
 {
-	MsnUserList *userlist;
+	MsnSlpLink *slplink;
 	const char *info;
 	PurpleAccount *account;
 
 	g_return_if_fail(slpcall != NULL);
+	slplink = slpcall->slplink;
 
 	info = slpcall->data_info;
 	if (purple_debug_is_verbose())
-		purple_debug_info("msn", "Got User Display: %s\n", slpcall->slplink->remote_user);
-
-	userlist = slpcall->slplink->session->userlist;
-	account = slpcall->slplink->session->account;
-
-	purple_buddy_icons_set_for_user(account, slpcall->slplink->remote_user,
-								  g_memdup(data, size), size, info);
+		purple_debug_info("msn", "Got User Display: %s\n", slplink->remote_user);
 
-#if 0
-	/* Free one window slot */
-	userlist->buddy_icon_window++;
+	account = slplink->session->account;
 
-	purple_debug_info("msn", "got_user_display(): buddy_icon_window++ yields =%d\n",
-					userlist->buddy_icon_window);
-
-	msn_release_buddy_icon_request(userlist);
-#endif
+	purple_buddy_icons_set_for_user(account, slplink->remote_user,
+								  g_memdup(data, size), size, info);
 }
 
 static void
--- a/libpurple/protocols/msn/switchboard.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/msn/switchboard.c	Mon Aug 23 00:52:24 2010 +0000
@@ -761,12 +761,8 @@
 static void
 iro_cmd(MsnCmdProc *cmdproc, MsnCommand *cmd)
 {
-	PurpleAccount *account;
-	PurpleConnection *gc;
 	MsnSwitchBoard *swboard;
 
-	account = cmdproc->session->account;
-	gc = account->gc;
 	swboard = cmdproc->data;
 
 	swboard->total_users = atoi(cmd->params[2]);
@@ -778,16 +774,12 @@
 joi_cmd(MsnCmdProc *cmdproc, MsnCommand *cmd)
 {
 	MsnSession *session;
-	PurpleAccount *account;
-	PurpleConnection *gc;
 	MsnSwitchBoard *swboard;
 	const char *passport;
 
 	passport = cmd->params[0];
 
 	session = cmdproc->session;
-	account = session->account;
-	gc = account->gc;
 	swboard = cmdproc->data;
 
 	msn_switchboard_add_user(swboard, passport);
--- a/libpurple/protocols/qq/buddy_info.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/qq/buddy_info.c	Mon Aug 23 00:52:24 2010 +0000
@@ -224,12 +224,10 @@
 void qq_request_buddy_info(PurpleConnection *gc, guint32 uid,
 		guint32 update_class, int action)
 {
-	qq_data *qd;
 	gchar raw_data[16] = {0};
 
 	g_return_if_fail(uid != 0);
 
-	qd = (qq_data *) gc->proto_data;
 	g_snprintf(raw_data, sizeof(raw_data), "%u", uid);
 	qq_send_cmd_mess(gc, QQ_CMD_GET_BUDDY_INFO, (guint8 *) raw_data, strlen(raw_data),
 			update_class, action);
@@ -271,7 +269,6 @@
 static void info_modify_ok_cb(modify_info_request *info_request, PurpleRequestFields *fields)
 {
 	PurpleConnection *gc;
-	qq_data *qd;
 	gchar **segments;
 	int index;
 	const char *utf8_str;
@@ -279,8 +276,7 @@
 	int choice_num;
 
 	gc = info_request->gc;
-	g_return_if_fail(gc != NULL && info_request->gc);
-	qd = (qq_data *) gc->proto_data;
+	g_return_if_fail(gc != NULL);
 	segments = info_request->segments;
 	g_return_if_fail(segments != NULL);
 
@@ -390,14 +386,12 @@
 
 static void info_modify_dialogue(PurpleConnection *gc, gchar **segments, int iclass)
 {
-	qq_data *qd;
 	PurpleRequestFieldGroup *group;
 	PurpleRequestFields *fields;
 	modify_info_request *info_request;
 	gchar *utf8_title, *utf8_prim;
 	int index;
 
-	qd = (qq_data *) gc->proto_data;
 	/* Keep one dialog once a time */
 	purple_request_close_with_handle(gc);
 
@@ -416,9 +410,11 @@
 		case QQ_FIELD_CONTACT:
 			utf8_title = g_strdup(_("Modify Contact"));
 			utf8_prim = g_strdup_printf("%s for %s", _("Modify Contact"), segments[0]);
+			break;
 		case QQ_FIELD_ADDR:
 			utf8_title = g_strdup(_("Modify Address"));
 			utf8_prim = g_strdup_printf("%s for %s", _("Modify Address"), segments[0]);
+			break;
 		case QQ_FIELD_EXT:
 			utf8_title = g_strdup(_("Modify Extended Information"));
 			utf8_prim = g_strdup_printf("%s for %s", _("Modify Extended Information"), segments[0]);
@@ -427,6 +423,7 @@
 		default:
 			utf8_title = g_strdup(_("Modify Information"));
 			utf8_prim = g_strdup_printf("%s for %s", _("Modify Information"), segments[0]);
+			break;
 	}
 
 	info_request = g_new0(modify_info_request, 1);
--- a/libpurple/protocols/qq/buddy_list.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/qq/buddy_list.c	Mon Aug 23 00:52:24 2010 +0000
@@ -55,11 +55,9 @@
 /* get a list of online_buddies */
 void qq_request_get_buddies_online(PurpleConnection *gc, guint8 position, guint32 update_class)
 {
-	qq_data *qd;
 	guint8 *raw_data;
 	gint bytes = 0;
 
-	qd = (qq_data *) gc->proto_data;
 	raw_data = g_newa(guint8, 5);
 
 	/* 000-000 get online friends cmd
@@ -360,7 +358,6 @@
 
 guint32 qq_process_get_buddies_and_rooms(guint8 *data, gint data_len, PurpleConnection *gc)
 {
-	qq_data *qd;
 	gint i, j;
 	gint bytes;
 	guint8 sub_cmd, reply_code;
@@ -371,8 +368,6 @@
 
 	g_return_val_if_fail(data != NULL && data_len != 0, -1);
 
-	qd = (qq_data *) gc->proto_data;
-
 	bytes = 0;
 	bytes += qq_get8(&sub_cmd, data + bytes);
 	g_return_val_if_fail(sub_cmd == 0x01, -1);
@@ -468,11 +463,6 @@
 	guint8 away_cmd;
 	guint32 misc_status;
 	gboolean fake_video;
-	PurpleAccount *account;
-	PurplePresence *presence;
-
-	account = purple_connection_get_account(gc);
-	presence = purple_account_get_presence(account);
 
 	qd = (qq_data *) gc->proto_data;
 	if (!qd->is_login)
@@ -596,14 +586,13 @@
 void qq_update_buddy_status(PurpleConnection *gc, guint32 uid, guint8 status, guint8 flag)
 {
 	gchar *who;
-	gchar *status_id;
+	const gchar *status_id;
 
 	g_return_if_fail(uid != 0);
 
 	/* purple supports signon and idle time
 	 * but it is not much use for QQ, I do not use them */
 	/* serv_got_update(gc, name, online, 0, q_bud->signon, q_bud->idle, bud->uc); */
-	status_id = "available";
 	switch(status) {
 	case QQ_BUDDY_OFFLINE:
 		status_id = "offline";
@@ -677,13 +666,10 @@
 
 void qq_buddy_data_free_all(PurpleConnection *gc)
 {
-	qq_data *qd;
 	PurpleBuddy *buddy;
 	GSList *buddies, *it;
 	gint count = 0;
 
-	qd = (qq_data *)purple_connection_get_protocol_data(gc);
-
 	buddies = purple_find_buddies(purple_connection_get_account(gc), NULL);
 	for (it = buddies; it; it = it->next) {
 		qq_buddy_data *qbd = NULL;
--- a/libpurple/protocols/qq/buddy_opt.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/qq/buddy_opt.c	Mon Aug 23 00:52:24 2010 +0000
@@ -262,7 +262,6 @@
 
 void qq_process_auth_code(PurpleConnection *gc, guint8 *data, gint data_len, guint32 uid)
 {
-	qq_data *qd;
 	gint bytes;
 	guint8 cmd, reply;
 	guint16 sub_cmd;
@@ -272,8 +271,6 @@
 	g_return_if_fail(data != NULL && data_len != 0);
 	g_return_if_fail(uid != 0);
 
-	qd = (qq_data *) gc->proto_data;
-
 	qq_show_packet("qq_process_auth_code", data, data_len);
 	bytes = 0;
 	bytes += qq_get8(&cmd, data + bytes);
@@ -400,7 +397,6 @@
 
 void qq_process_question(PurpleConnection *gc, guint8 *data, gint data_len, guint32 uid)
 {
-	qq_data *qd;
 	gint bytes;
 	guint8 cmd, reply;
 	gchar *question, *answer;
@@ -409,8 +405,6 @@
 
 	g_return_if_fail(data != NULL && data_len != 0);
 
-	qd = (qq_data *) gc->proto_data;
-
 	qq_show_packet("qq_process_question", data, data_len);
 	bytes = 0;
 	bytes += qq_get8(&cmd, data + bytes);
@@ -720,13 +714,10 @@
 /*  process reply to add_buddy_auth request */
 void qq_process_add_buddy_auth(guint8 *data, gint data_len, PurpleConnection *gc)
 {
-	qq_data *qd;
 	gchar **segments, *msg_utf8;
 
 	g_return_if_fail(data != NULL && data_len != 0);
 
-	qd = (qq_data *) gc->proto_data;
-
 	if (data[0] == '0') {
 		purple_debug_info("QQ", "Reply OK for sending authorize\n");
 		return;
@@ -767,11 +758,9 @@
 /* process the server reply for my request to remove myself from a buddy */
 void qq_process_buddy_remove_me(PurpleConnection *gc, guint8 *data, gint data_len, guint32 uid)
 {
-	qq_data *qd;
 	gchar *msg;
 
 	g_return_if_fail(data != NULL && data_len != 0);
-	qd = (qq_data *) gc->proto_data;
 
 	if (data[0] == 0) {
 		purple_debug_info("QQ", "Reply OK for removing me from %u's buddy list\n", uid);
@@ -1004,7 +993,6 @@
 
 void qq_process_buddy_check_code(PurpleConnection *gc, guint8 *data, gint data_len)
 {
-	qq_data *qd;
 	gint bytes;
 	guint8 cmd;
 	guint8 reply;
@@ -1013,8 +1001,6 @@
 
 	g_return_if_fail(data != NULL && data_len >= 5);
 
-	qd = (qq_data *) gc->proto_data;
-
 	qq_show_packet("buddy_check_code", data, data_len);
 
 	bytes = 0;
--- a/libpurple/protocols/qq/file_trans.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/qq/file_trans.c	Mon Aug 23 00:52:24 2010 +0000
@@ -238,12 +238,9 @@
 	gint bytes = 0;
 	guint32 file_key;
 	qq_data *qd;
-	ft_info *info;
 
 	qd = (qq_data *) gc->proto_data;
 
-	info = (ft_info *) qd->xfer->data;
-
 	raw_data = g_newa(guint8, MAX_PACKET_SIZE);
 	file_key = _gen_file_key();
 
@@ -805,9 +802,6 @@
 {
 	gint bytes;
 	guint8 tag;
-	qq_data *qd;
-
-	qd = (qq_data *) gc->proto_data;
 
 	bytes = 0;
 	bytes += qq_get8(&tag, data + bytes);
--- a/libpurple/protocols/qq/group.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/qq/group.c	Mon Aug 23 00:52:24 2010 +0000
@@ -119,13 +119,11 @@
 /* free roomlist space, I have no idea when this one is called... */
 void qq_roomlist_cancel(PurpleRoomlist *list)
 {
-	qq_data *qd;
 	PurpleConnection *gc;
 
 	g_return_if_fail(list != NULL);
 	gc = purple_account_get_connection(list->account);
 
-	qd = (qq_data *) gc->proto_data;
 	purple_roomlist_set_in_progress(list, FALSE);
 	purple_roomlist_unref(list);
 }
--- a/libpurple/protocols/qq/group_im.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/qq/group_im.c	Mon Aug 23 00:52:24 2010 +0000
@@ -48,12 +48,10 @@
 PurpleConversation *qq_room_conv_open(PurpleConnection *gc, qq_room_data *rmd)
 {
 	PurpleConversation *conv;
-	qq_data *qd;
 	gchar *topic_utf8;
 
 	g_return_val_if_fail(rmd != NULL, NULL);
 	g_return_val_if_fail(rmd->title_utf8, NULL);
-	qd = (qq_data *) gc->proto_data;
 
 	conv = purple_find_conversation_with_account(PURPLE_CONV_TYPE_CHAT,
 			rmd->title_utf8, purple_connection_get_account(gc));
@@ -207,7 +205,6 @@
 /* recv an IM from a group chat */
 void qq_process_room_im(guint8 *data, gint data_len, guint32 id, PurpleConnection *gc, guint16 msg_type)
 {
-	qq_data *qd;
 	gchar *msg_smiley, *msg_fmt, *msg_utf8;
 	gint bytes, tail_len;
 	struct {
@@ -229,7 +226,6 @@
 
 	/* at least include im_text.msg_len */
 	g_return_if_fail(data != NULL && data_len > 23);
-	qd = (qq_data *) gc->proto_data;
 
 	/* qq_show_packet("ROOM_IM", data, data_len); */
 	memset(&im_text, 0, sizeof(im_text));
@@ -376,7 +372,6 @@
 	gint msg_len;
 	const gchar *start_invalid;
 	gboolean is_smiley_none;
-	guint8 frag_count, frag_index;
 
 	g_return_val_if_fail(NULL != gc && NULL != gc->proto_data, -1);
 	g_return_val_if_fail(id != 0 && what != NULL, -1);
@@ -386,9 +381,6 @@
 
 	/* qq_show_packet("chat IM UTF8", (guint8 *)what, strlen(what)); */
 
-	fmt = qq_im_fmt_new_by_purple(what);
-	is_smiley_none = qq_im_smiley_none(what);
-
 	msg_stripped = purple_markup_strip_html(what);
 	g_return_val_if_fail(msg_stripped != NULL, -1);
 	/* qq_show_packet("IM Stripped", (guint8 *)what, strlen(what)); */
@@ -417,26 +409,10 @@
 
 	qd->send_im_id++;
 	fmt = qq_im_fmt_new_by_purple(what);
-	frag_count = g_slist_length(segments);
-	frag_index = 0;
-/*
-	if (frag_count <= 1) {
-*/
-		for (it = segments; it; it = it->next) {
-			request_room_send_im(gc, id, fmt, (gchar *)it->data);
-			g_free(it->data);
-		}
-/*
-	} else {
-		for (it = segments; it; it = it->next) {
-			request_room_send_im_ex(gc, id, fmt, (gchar *)it->data,
-					qd->send_im_id, frag_count, frag_index);
-			g_free(it->data);
-			frag_index++;
-		}
+	for (it = segments; it; it = g_slist_delete_link(it, it)) {
+		request_room_send_im(gc, id, fmt, (gchar *)it->data);
+		g_free(it->data);
 	}
-*/
 	qq_im_fmt_free(fmt);
-	g_slist_free(segments);
 	return 1;
 }
--- a/libpurple/protocols/qq/group_join.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/qq/group_join.c	Mon Aug 23 00:52:24 2010 +0000
@@ -178,12 +178,10 @@
 /* If comes here, cmd is OK already */
 void qq_process_group_cmd_exit_group(guint8 *data, gint len, PurpleConnection *gc)
 {
-	qq_data *qd;
 	gint bytes;
 	guint32 id;
 
 	g_return_if_fail(data != NULL && len > 0);
-	qd = (qq_data *) gc->proto_data;
 
 	if (len < 4) {
 		purple_debug_error("QQ", "Invalid exit group reply, expect %d bytes, read %d bytes\n", 4, len);
@@ -201,12 +199,10 @@
 {
 	gint bytes;
 	guint32 id;
-	qq_data *qd;
 	qq_room_data *rmd;
 	gchar *msg;
 
 	g_return_if_fail(data != NULL && len > 0);
-	qd = (qq_data *) gc->proto_data;
 
 	if (len < 4) {
 		purple_debug_error("QQ",
@@ -283,7 +279,6 @@
 /* Attempt to join a group without auth */
 void qq_group_join(PurpleConnection *gc, GHashTable *data)
 {
-	qq_data *qd;
 	gchar *ext_id_str;
 	gchar *id_str;
 	guint32 ext_id;
@@ -291,7 +286,6 @@
 	qq_room_data *rmd;
 
 	g_return_if_fail(data != NULL);
-	qd = (qq_data *) gc->proto_data;
 
 	ext_id_str = g_hash_table_lookup(data, QQ_ROOM_KEY_EXTERNAL_ID);
 	id_str = g_hash_table_lookup(data, QQ_ROOM_KEY_INTERNAL_ID);
--- a/libpurple/protocols/qq/group_opt.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/qq/group_opt.c	Mon Aug 23 00:52:24 2010 +0000
@@ -134,12 +134,10 @@
 {
 	guint32 *old_members, *del_members, *add_members;
 	qq_buddy_data *bd;
-	qq_data *qd;
 	gint i = 0, old = 0, new = 0, del = 0, add = 0;
 	GList *list;
 
 	g_return_if_fail(rmd != NULL);
-	qd = (qq_data *) gc->proto_data;
 	if (new_members[0] == 0xffffffff)
 		return;
 
--- a/libpurple/protocols/qq/im.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/qq/im.c	Mon Aug 23 00:52:24 2010 +0000
@@ -725,7 +725,6 @@
 /* process received normal text IM */
 static void process_im_text(PurpleConnection *gc, guint8 *data, gint len, qq_im_header *im_header)
 {
-	qq_data *qd;
 	guint16 purple_msg_type;
 	gchar *who;
 	gchar *msg_smiley, *msg_fmt, *msg_utf8;
@@ -749,10 +748,9 @@
 		gchar *msg;		/* no fixed length, ends with 0x00 */
 	} im_text;
 
-	g_return_if_fail (data != NULL && len > 0);
+	g_return_if_fail(data != NULL && len > 0);
 	g_return_if_fail(im_header != NULL);
 
-	qd = (qq_data *) gc->proto_data;
 	memset(&im_text, 0, sizeof(im_text));
 
 	/* qq_show_packet("IM text", data, len); */
@@ -823,7 +821,6 @@
 /* process received extended (2007) text IM */
 static void process_extend_im_text(PurpleConnection *gc, guint8 *data, gint len, qq_im_header *im_header)
 {
-	qq_data *qd;
 	guint16 purple_msg_type;
 	gchar *who;
 	gchar *msg_smiley, *msg_fmt, *msg_utf8;
@@ -848,10 +845,9 @@
 		guint8 fromMobileQQ;
 	} im_text;
 
-	g_return_if_fail (data != NULL && len > 0);
+	g_return_if_fail(data != NULL && len > 0);
 	g_return_if_fail(im_header != NULL);
 
-	qd = (qq_data *) gc->proto_data;
 	memset(&im_text, 0, sizeof(im_text));
 
 	/* qq_show_packet("Extend IM text", data, len); */
@@ -1043,12 +1039,10 @@
 {
 	qq_data *qd;
 	guint8 raw_data[MAX_PACKET_SIZE - 16];
-	guint16 im_type;
 	gint bytes;
 	time_t now;
 
 	qd = (qq_data *) gc->proto_data;
-	im_type = QQ_NORMAL_IM_TEXT;
 
 	/* purple_debug_info("QQ", "Send IM %d-%d\n", frag_count, frag_index); */
 	bytes = 0;
@@ -1118,13 +1112,12 @@
 	GString *new_string;
 	GString *append_utf8;
 	gchar *start, *p;
-	gint count, len;
+	gint len;
 	qq_emoticon *emoticon;
 
 	g_return_val_if_fail(msg_stripped != NULL, NULL);
 
 	start = msg_stripped;
-	count = 0;
 	new_string = g_string_new("");
 	append_utf8 = g_string_new("");
 	while (*start) {
--- a/libpurple/protocols/qq/qq.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/qq/qq.c	Mon Aug 23 00:52:24 2010 +0000
@@ -89,15 +89,12 @@
 {
 	PurpleConnection *gc;
 	qq_data *qd;
-	PurpleProxyInfo *gpi;
 	const gchar *custom_server;
 
 	gc = purple_account_get_connection(account);
 	g_return_if_fail(gc != NULL  && gc->proto_data != NULL);
 	qd = gc->proto_data;
 
-	gpi = purple_proxy_get_setup(account);
-
 	qd->use_tcp = purple_account_get_bool(account, "use_tcp", TRUE);
 
 	custom_server = purple_account_get_string(account, "server", NULL);
@@ -617,12 +614,10 @@
 static void action_about_openq(PurplePluginAction *action)
 {
 	PurpleConnection *gc = (PurpleConnection *) action->context;
-	qq_data *qd;
 	GString *info;
 	gchar *title;
 
-	g_return_if_fail(NULL != gc && NULL != gc->proto_data);
-	qd = (qq_data *) gc->proto_data;
+	g_return_if_fail(NULL != gc);
 
 	info = g_string_new("<html><body>");
 	g_string_append(info, _("<p><b>Original Author</b>:<br>\n"));
--- a/libpurple/protocols/qq/qq_base.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/qq/qq_base.c	Mon Aug 23 00:52:24 2010 +0000
@@ -386,7 +386,6 @@
 /* process the login reply packet */
 guint8 qq_process_login( PurpleConnection *gc, guint8 *data, gint data_len)
 {
-	qq_data *qd;
 	guint8 ret = data[0];
 	gchar *msg, *msg_utf8;
 	gchar *error;
@@ -394,8 +393,6 @@
 
 	g_return_val_if_fail(data != NULL && data_len != 0, QQ_LOGIN_REPLY_ERR);
 
-	qd = (qq_data *) gc->proto_data;
-
 	switch (ret) {
 		case QQ_LOGIN_REPLY_OK:
 			purple_debug_info("QQ", "Login OK\n");
--- a/libpurple/protocols/qq/qq_network.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/qq/qq_network.c	Mon Aug 23 00:52:24 2010 +0000
@@ -482,13 +482,11 @@
 static void udp_pending(gpointer data, gint source, PurpleInputCondition cond)
 {
 	PurpleConnection *gc = NULL;
-	qq_data *qd;
 	guint8 *buf;
 	gint buf_len;
 
 	gc = (PurpleConnection *) data;
-	g_return_if_fail(gc != NULL && gc->proto_data != NULL);
-	qd = (qq_data *) gc->proto_data;
+	g_return_if_fail(gc != NULL);
 
 	if(cond != PURPLE_INPUT_READ) {
 		purple_connection_error_reason(gc,
@@ -748,14 +746,12 @@
 {
 	PurpleConnection *gc;
 	qq_data *qd;
-	PurpleAccount *account ;
 	qq_connection *conn;
 
 	gc = (PurpleConnection *) data;
 	g_return_if_fail(gc != NULL && gc->proto_data != NULL);
 
 	qd = (qq_data *) gc->proto_data;
-	account = purple_connection_get_account(gc);
 
 	/* conn_data will be destoryed */
 	qd->conn_data = NULL;
--- a/libpurple/protocols/qq/qq_process.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/qq/qq_process.c	Mon Aug 23 00:52:24 2010 +0000
@@ -58,15 +58,12 @@
 /* default process, decrypt and dump */
 static void process_unknow_cmd(PurpleConnection *gc,const gchar *title, guint8 *data, gint data_len, guint16 cmd, guint16 seq)
 {
-	qq_data *qd;
 	gchar *msg;
 
 	g_return_if_fail(data != NULL && data_len != 0);
 
 	qq_show_packet(title, data, data_len);
 
-	qd = (qq_data *) gc->proto_data;
-
 	qq_hex_dump(PURPLE_DEBUG_WARNING, "QQ",
 			data, data_len,
 			">>> [%d] %s -> [default] decrypt and dump",
@@ -80,12 +77,8 @@
 /* parse the reply to send_im */
 static void do_im_ack(guint8 *data, gint data_len, PurpleConnection *gc)
 {
-	qq_data *qd;
-
 	g_return_if_fail(data != NULL && data_len != 0);
 
-	qd = gc->proto_data;
-
 	if (data[0] != 0) {
 		purple_debug_warning("QQ", "Failed sent IM\n");
 		purple_notify_error(gc, _("Error"), _("Unable to send message."), NULL);
@@ -380,14 +373,11 @@
 /* Send ACK if the sys message needs an ACK */
 static void request_server_ack(PurpleConnection *gc, gchar *funct_str, gchar *from, guint16 seq)
 {
-	qq_data *qd;
 	guint8 *raw_data;
 	gint bytes;
 	guint8 bar;
 
 	g_return_if_fail(funct_str != NULL && from != NULL);
-	qd = (qq_data *) gc->proto_data;
-
 
 	bar = 0x1e;
 	raw_data = g_newa(guint8, strlen(funct_str) + strlen(from) + 16);
@@ -568,11 +558,9 @@
 
 void qq_update_room(PurpleConnection *gc, guint8 room_cmd, guint32 room_id)
 {
-	qq_data *qd;
 	gint ret;
 
-	g_return_if_fail (gc != NULL && gc->proto_data != NULL);
-	qd = (qq_data *) gc->proto_data;
+	g_return_if_fail (gc != NULL);
 
 	switch (room_cmd) {
 		case 0:
@@ -599,12 +587,10 @@
 
 void qq_update_all_rooms(PurpleConnection *gc, guint8 room_cmd, guint32 room_id)
 {
-	qq_data *qd;
 	gboolean is_new_turn = FALSE;
 	guint32 next_id;
 
-	g_return_if_fail (gc != NULL && gc->proto_data != NULL);
-	qd = (qq_data *) gc->proto_data;
+	g_return_if_fail(gc != NULL);
 
 	next_id = qq_room_get_next(gc, room_id);
 	purple_debug_info("QQ", "Update rooms, next id %u, prev id %u\n", next_id, room_id);
@@ -689,11 +675,9 @@
 
 static void update_all_rooms_online(PurpleConnection *gc, guint8 room_cmd, guint32 room_id)
 {
-	qq_data *qd;
 	guint32 next_id;
 
-	g_return_if_fail (gc != NULL && gc->proto_data != NULL);
-	qd = (qq_data *) gc->proto_data;
+	g_return_if_fail (gc != NULL);
 
 	next_id = qq_room_get_next_conv(gc, room_id);
 	if (next_id <= 0 && room_id <= 0) {
--- a/libpurple/protocols/qq/qq_trans.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/qq/qq_trans.c	Mon Aug 23 00:52:24 2010 +0000
@@ -109,11 +109,9 @@
 static qq_transaction *trans_create(PurpleConnection *gc, gint fd,
 	guint16 cmd, guint16 seq, guint8 *data, gint data_len, guint32 update_class, guint32 ship32)
 {
-	qq_data *qd;
 	qq_transaction *trans;
 
-	g_return_val_if_fail(gc != NULL && gc->proto_data != NULL, NULL);
-	qd = (qq_data *) gc->proto_data;
+	g_return_val_if_fail(gc != NULL, NULL);
 
 	trans = g_new0(qq_transaction, 1);
 
--- a/libpurple/protocols/qq/send_file.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/qq/send_file.c	Mon Aug 23 00:52:24 2010 +0000
@@ -637,10 +637,8 @@
 {
 	PurpleConnection *gc;
 	PurpleAccount *account;
-	guint16 *seq;
 
 	g_return_if_fail (xfer != NULL);
-	seq = (guint16 *) xfer->data;
 	account = purple_xfer_get_account(xfer);
 	gc = purple_account_get_connection(account);
 
@@ -670,10 +668,8 @@
 {
 	PurpleConnection *gc;
 	PurpleAccount *account;
-	ft_info *info;
 
-	g_return_if_fail (xfer != NULL && xfer->data != NULL);
-	info = (ft_info *) xfer->data;
+	g_return_if_fail(xfer != NULL);
 	account = purple_xfer_get_account(xfer);
 	gc = purple_account_get_connection(account);
 
@@ -752,7 +748,7 @@
 	g_return_if_fail (data != NULL && data_len != 0);
 	qd = (qq_data *) gc->proto_data;
 	xfer = qd->xfer;
-	info = (ft_info *) qd->xfer->data;
+	info = (ft_info *) xfer->data;
 
 	if (data_len <= 30 + QQ_CONN_INFO_LEN) {
 		purple_debug_warning("QQ", "Received file reject message is empty\n");
@@ -761,7 +757,7 @@
 
 	bytes = 18 + 12;	/* skip 30 bytes */
 	qq_get_conn_info(info, data + bytes);
-	_qq_xfer_init_socket(qd->xfer);
+	_qq_xfer_init_socket(xfer);
 
 	_qq_xfer_init_udp_channel(info);
 	_qq_send_packet_file_notifyip(gc, sender_uid);
--- a/libpurple/protocols/yahoo/libymsg.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/yahoo/libymsg.c	Mon Aug 23 00:52:24 2010 +0000
@@ -3906,7 +3906,6 @@
 	PurpleBuddy *buddy;
 	PurpleConnection *gc;
 
-	YahooData *yd;
 	const char *game;
 	char *game2;
 	char *t;
@@ -3917,7 +3916,6 @@
 
 	buddy = (PurpleBuddy *) node;
 	gc = purple_account_get_connection(purple_buddy_get_account(buddy));
-	yd = (YahooData *) gc->proto_data;
 
 	f = yahoo_friend_find(gc, purple_buddy_get_name(buddy));
 	if (!f)
@@ -4941,7 +4939,6 @@
 	struct yahoo_packet *pkt;
 	const char *group = NULL;
 	char *group2;
-	YahooFriend *f;
 	const char *bname;
 	const char *fed_bname;
 	YahooFederation fed = YAHOO_FEDERATION_NONE;
@@ -4953,7 +4950,6 @@
 	if (!purple_privacy_check(purple_connection_get_account(gc), bname))
 		return;
 
-	f = yahoo_friend_find(gc, bname);
 	fed = yahoo_get_federation_from_name(bname);
 	if (fed != YAHOO_FEDERATION_NONE)
 		fed_bname += 4;
@@ -5216,15 +5212,11 @@
 {
 	GHashTable *comp;
 	PurpleConnection *gc;
-	YahooData *yd;
-	int id;
 
 	if (!args || !args[0])
 		return PURPLE_CMD_RET_FAILED;
 
 	gc = purple_conversation_get_gc(conv);
-	yd = gc->proto_data;
-	id = yd->conf_id;
 	purple_debug_info("yahoo", "Trying to join %s \n", args[0]);
 
 	comp = g_hash_table_new_full(g_str_hash, g_str_equal, g_free, g_free);
--- a/libpurple/protocols/yahoo/yahoo_filexfer.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/yahoo/yahoo_filexfer.c	Mon Aug 23 00:52:24 2010 +0000
@@ -1235,14 +1235,14 @@
 	PurpleXfer *xfer;
 	struct yahoo_xfer_data *xd;
 	PurpleAccount *account;
-	YahooData* yd;
+	PurpleConnection *gc;
 
 	if (!(xfer = data))
 		return;
 	if (!(xd = xfer->data))
 		return;
-	yd = xd->gc->proto_data;
-	account = purple_connection_get_account(xd->gc);
+	gc = xd->gc;
+	account = purple_connection_get_account(gc);
 	if ((source < 0) || (xd->path == NULL) || (xd->host == NULL)) {
 		purple_xfer_error(PURPLE_XFER_RECEIVE, purple_xfer_get_account(xfer),
 			xfer->who, _("Unable to connect."));
@@ -1253,7 +1253,7 @@
 	if (xd->txbuflen == 0)
 	{
 		gchar* cookies;
-		cookies = yahoo_get_cookies(xd->gc);
+		cookies = yahoo_get_cookies(gc);
 		if(purple_xfer_get_type(xfer) == PURPLE_XFER_SEND && xd->status_15 == ACCEPTED)
 		{
 			if(xd->info_val_249 == 2)
--- a/libpurple/protocols/yahoo/yahoochat.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/libpurple/protocols/yahoo/yahoochat.c	Mon Aug 23 00:52:24 2010 +0000
@@ -617,9 +617,6 @@
 	char *who = NULL;
 	char *room = NULL;
 	GSList *l;
-	YahooData *yd;
-
-	yd = gc->proto_data;
 
 	for (l = pkt->hash; l; l = l->next) {
 		struct yahoo_pair *pair = l->data;
@@ -638,8 +635,7 @@
 			purple_conv_chat_remove_user(PURPLE_CONV_CHAT(c), who, NULL);
 
 	}
-	if (room)
-		g_free(room);
+	g_free(room);
 }
 
 void yahoo_process_chat_message(PurpleConnection *gc, struct yahoo_packet *pkt)
--- a/pidgin/gtkblist.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/pidgin/gtkblist.c	Mon Aug 23 00:52:24 2010 +0000
@@ -3965,7 +3965,6 @@
 			                                 tmp);
 			g_free(tmp);
 		}
-		count = 0;
 
 		count = purple_blist_get_group_size(group, FALSE);
 		if (count != 0) {
@@ -3976,7 +3975,6 @@
 			                                 tmp);
 			g_free(tmp);
 		}
-		count = 0;
 
 		tmp = purple_notify_user_info_get_text_with_newline(user_info, "\n");
 		g_string_append(str, tmp);
@@ -4023,7 +4021,6 @@
 {
 	PurpleBuddy *buddy = NULL;
 	struct _pidgin_blist_node *gtknode = node->ui_data;
-	struct _pidgin_blist_node *gtkbuddynode = NULL;
 	PurplePlugin *prpl;
 	PurplePluginProtocolInfo *prpl_info;
 	const char *name = NULL;
@@ -4034,11 +4031,9 @@
 	if(PURPLE_BLIST_NODE_IS_CONTACT(node)) {
 		if(!gtknode->contact_expanded) {
 			buddy = purple_contact_get_priority_buddy((PurpleContact*)node);
-			gtkbuddynode = ((PurpleBlistNode*)buddy)->ui_data;
 		}
 	} else if(PURPLE_BLIST_NODE_IS_BUDDY(node)) {
 		buddy = (PurpleBuddy*)node;
-		gtkbuddynode = node->ui_data;
 		p = purple_buddy_get_presence(buddy);
 		if (purple_presence_is_status_primitive_active(p, PURPLE_STATUS_MOBILE)) {
 			/* This emblem comes from the small emoticon set now,
@@ -4131,7 +4126,6 @@
 pidgin_blist_get_status_icon(PurpleBlistNode *node, PidginStatusIconSize size)
 {
 	GdkPixbuf *ret;
-	const char *protoname = NULL;
 	const char *icon = NULL;
 	struct _pidgin_blist_node *gtknode = node->ui_data;
 	struct _pidgin_blist_node *gtkbuddynode = NULL;
@@ -4158,7 +4152,6 @@
 	if(buddy || chat) {
 		PurpleAccount *account;
 		PurplePlugin *prpl;
-		PurplePluginProtocolInfo *prpl_info;
 
 		if(buddy)
 			account = buddy->account;
@@ -4168,12 +4161,6 @@
 		prpl = purple_find_prpl(purple_account_get_protocol_id(account));
 		if(!prpl)
 			return NULL;
-
-		prpl_info = PURPLE_PLUGIN_PROTOCOL_INFO(prpl);
-
-		if(prpl_info && prpl_info->list_icon) {
-			protoname = prpl_info->list_icon(account, buddy);
-		}
 	}
 
 	if(buddy) {
--- a/pidgin/gtkconv.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/pidgin/gtkconv.c	Mon Aug 23 00:52:24 2010 +0000
@@ -750,9 +750,9 @@
 do_invite(GtkWidget *w, int resp, InviteBuddyInfo *info)
 {
 	const char *buddy, *message;
-	PidginConversation *gtkconv;
-
-	gtkconv = PIDGIN_CONVERSATION(info->conv);
+	PurpleConversation *conv;
+
+	conv = info->conv;
 
 	if (resp == GTK_RESPONSE_OK) {
 		buddy   = gtk_entry_get_text(GTK_ENTRY(info->entry));
@@ -761,8 +761,8 @@
 		if (!g_ascii_strcasecmp(buddy, ""))
 			return;
 
-		serv_chat_invite(purple_conversation_get_gc(info->conv),
-						 purple_conv_chat_get_id(PURPLE_CONV_CHAT(info->conv)),
+		serv_chat_invite(purple_conversation_get_gc(conv),
+						 purple_conv_chat_get_id(PURPLE_CONV_CHAT(conv)),
 						 message, buddy);
 	}
 
@@ -856,7 +856,6 @@
 	InviteBuddyInfo *info = NULL;
 
 	if (invite_dialog == NULL) {
-		PurpleConnection *gc;
 		PidginWindow *gtkwin;
 		GtkWidget *label;
 		GtkWidget *vbox, *hbox;
@@ -869,7 +868,6 @@
 		info = g_new0(InviteBuddyInfo, 1);
 		info->conv = conv;
 
-		gc        = purple_conversation_get_gc(conv);
 		gtkwin    = pidgin_conv_get_window(gtkconv);
 
 		/* Create the new dialog. */
@@ -1200,12 +1198,10 @@
 menu_insert_image_cb(gpointer data, guint action, GtkWidget *widget)
 {
 	PidginWindow *win = data;
-	PurpleConversation *conv;
 	PidginConversation *gtkconv;
 	GtkIMHtmlToolbar *toolbar;
 
 	gtkconv = pidgin_conv_window_get_active_gtkconv(win);
-	conv    = gtkconv->active_conv;
 	toolbar = GTK_IMHTMLTOOLBAR(gtkconv->toolbar);
 
 	gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(toolbar->image),
@@ -1911,10 +1907,8 @@
 conv_keypress_common(PidginConversation *gtkconv, GdkEventKey *event)
 {
 	PidginWindow *win;
-	PurpleConversation *conv;
 	int curconv;
 
-	conv     = gtkconv->active_conv;
 	win      = gtkconv->win;
 	curconv = gtk_notebook_get_current_page(GTK_NOTEBOOK(win->notebook));
 
@@ -2009,13 +2003,11 @@
 static gboolean
 entry_key_press_cb(GtkWidget *entry, GdkEventKey *event, gpointer data)
 {
-	PidginWindow *win;
 	PurpleConversation *conv;
 	PidginConversation *gtkconv;
 
 	gtkconv  = (PidginConversation *)data;
 	conv     = gtkconv->active_conv;
-	win      = gtkconv->win;
 
 	if (conv_keypress_common(gtkconv, event))
 		return TRUE;
@@ -2350,12 +2342,9 @@
 			   gchar *new_text, gint new_text_length, gpointer user_data)
 {
 	PidginConversation *gtkconv = (PidginConversation *)user_data;
-	PurpleConversation *conv;
 
 	g_return_if_fail(gtkconv != NULL);
 
-	conv = gtkconv->active_conv;
-
 	if (!purple_prefs_get_bool("/purple/conversations/im/send_typing"))
 		return;
 
@@ -2617,7 +2606,6 @@
 	PidginConversation *gtkconv = (PidginConversation *)data;
 	PurpleConversation *conv = gtkconv->active_conv;
 	PurpleAccount *account;
-	PurplePluginProtocolInfo *prpl_info = NULL;
 
 	GdkPixbuf *buf;
 	GdkPixbuf *scale;
@@ -2628,9 +2616,7 @@
 	gtkconv = PIDGIN_CONVERSATION(conv);
 	account = purple_conversation_get_account(conv);
 
-	if(account && account->gc) {
-		prpl_info = PURPLE_PLUGIN_PROTOCOL_INFO(account->gc->prpl);
-	} else {
+	if (!(account && account->gc)) {
 		gtkconv->u.im->icon_timer = 0;
 		return FALSE;
 	}
@@ -2702,7 +2688,6 @@
 	GList *children;
 	GtkWidget *event;
 	PurpleConversation *conv = gtkconv->active_conv;
-	PidginWindow *gtkwin;
 
 	g_return_if_fail(conv != NULL);
 
@@ -2730,8 +2715,6 @@
 	gtkconv->u.im->anim = NULL;
 	gtkconv->u.im->iter = NULL;
 	gtkconv->u.im->show_icon = FALSE;
-
-	gtkwin = gtkconv->win;
 }
 
 static void
@@ -3684,13 +3667,10 @@
 static void
 update_typing_icon(PidginConversation *gtkconv)
 {
-	PidginWindow *gtkwin;
 	PurpleConvIm *im = NULL;
 	PurpleConversation *conv = gtkconv->active_conv;
 	char *message = NULL;
 
-	gtkwin = gtkconv->win;
-
 	if (purple_conversation_get_type(conv) == PURPLE_CONV_TYPE_IM)
 		im = PURPLE_CONV_IM(conv);
 
@@ -5740,10 +5720,8 @@
 						time_t mtime)
 {
 	PidginConversation *gtkconv;
-	PidginWindow *win;
 	PurpleConnection *gc;
 	PurpleAccount *account;
-	PurplePluginProtocolInfo *prpl_info;
 	int gtk_font_options = 0;
 	int gtk_font_options_all = 0;
 	int max_scrollback_lines;
@@ -5830,9 +5808,6 @@
 		g_free(tmp);
 	}
 
-	win = gtkconv->win;
-	prpl_info = gc ? PURPLE_PLUGIN_PROTOCOL_INFO(gc->prpl) : NULL;
-
 	line_count = gtk_text_buffer_get_line_count(
 			gtk_text_view_get_buffer(GTK_TEXT_VIEW(
 				gtkconv->imhtml)));
@@ -6263,7 +6238,6 @@
 pidgin_conv_chat_update_user(PurpleConversation *conv, const char *user)
 {
 	PurpleConvChat *chat;
-	PurpleConvChatBuddyFlags flags;
 	PurpleConvChatBuddy *cbuddy;
 	PidginConversation *gtkconv;
 	PidginChatPane *gtkchat;
@@ -6306,8 +6280,6 @@
 
 	g_return_if_fail(alias != NULL);
 
-	flags = purple_conv_chat_user_get_flags(chat, user);
-
 	cbuddy = purple_conv_chat_cb_find(chat, user);
 	if (cbuddy)
 		add_chat_buddy_common(conv, cbuddy, NULL);
@@ -6729,7 +6701,6 @@
 		PurpleConvIm *im = NULL;
 		PurpleAccount *account = purple_conversation_get_account(conv);
 	 	PurpleBuddy *buddy = NULL;
-		PurplePresence *p = NULL;
 		char *markup = NULL;
 		AtkObject *accessibility_obj;
 		/* I think this is a little longer than it needs to be but I'm lazy. */
@@ -6749,7 +6720,6 @@
 		if (purple_conversation_get_type(conv) == PURPLE_CONV_TYPE_IM) {
 			buddy = purple_find_buddy(account, conv->name);
 			if (buddy) {
-				p = purple_buddy_get_presence(buddy);
 				markup = pidgin_blist_get_name_markup(buddy, FALSE, FALSE);
 			} else {
 				markup = title;
@@ -6964,7 +6934,6 @@
 	int size = 0;
 
 	PurpleAccount *account;
-	PurplePluginProtocolInfo *prpl_info = NULL;
 
 	PurpleBuddyIcon *icon;
 
@@ -6981,8 +6950,6 @@
 		return;
 
 	account = purple_conversation_get_account(conv);
-	if(account && account->gc)
-		prpl_info = PURPLE_PLUGIN_PROTOCOL_INFO(account->gc->prpl);
 
 	/* Remove the current icon stuff */
 	children = gtk_container_get_children(GTK_CONTAINER(gtkconv->u.im->icon_container));
@@ -8627,7 +8594,7 @@
 static gboolean
 notebook_press_cb(GtkWidget *widget, GdkEventButton *e, PidginWindow *win)
 {
-	gint nb_x, nb_y, x_rel, y_rel;
+	gint nb_x, nb_y;
 	int tab_clicked;
 	GtkWidget *page;
 	GtkWidget *tab;
@@ -8670,9 +8637,6 @@
 	*/
 	gdk_window_get_origin(win->notebook->window, &nb_x, &nb_y);
 
-	x_rel = e->x_root - nb_x;
-	y_rel = e->y_root - nb_y;
-
 	/* Reset the min/max x/y */
 	win->drag_min_x = 0;
 	win->drag_min_y = 0;
@@ -9239,6 +9203,7 @@
 	if (win && win->window &&
 			!GTK_WIDGET_VISIBLE(win->window) && conv_width != 0) {
 
+#ifdef _WIN32  /* only override window manager placement on Windows */
 		/* ...check position is on screen... */
 		if (conv_x >= gdk_screen_width())
 			conv_x = gdk_screen_width() - 100;
@@ -9251,7 +9216,6 @@
 			conv_y = 100;
 
 		/* ...and move it back. */
-#ifdef _WIN32  /* only override window manager placement on Windows */
 		gtk_window_move(GTK_WINDOW(win->window), conv_x, conv_y);
 #endif
 		gtk_window_resize(GTK_WINDOW(win->window), conv_width, conv_height);
@@ -9503,7 +9467,7 @@
 
 	gtk_widget_show(gtkconv->menu_tabby);
 
-	if (purple_conversation_get_type(conv) == PURPLE_CONV_TYPE_IM)
+	if (conv_type == PURPLE_CONV_TYPE_IM)
 		pidgin_conv_update_buddy_icon(conv);
 
 	/* Build and set conversations tab */
@@ -9630,9 +9594,7 @@
 pidgin_conv_window_remove_gtkconv(PidginWindow *win, PidginConversation *gtkconv)
 {
 	unsigned int index;
-	PurpleConversationType conv_type;
-
-	conv_type = purple_conversation_get_type(gtkconv->active_conv);
+
 	index = gtk_notebook_page_num(GTK_NOTEBOOK(win->notebook), gtkconv->tab_cont);
 
 	g_object_ref(gtkconv->tab_cont);
@@ -9965,12 +9927,9 @@
 static void
 conv_placement_by_group(PidginConversation *conv)
 {
-	PurpleConversationType type;
 	PurpleGroup *group = NULL;
 	GList *wl, *cl;
 
-	type = purple_conversation_get_type(conv->active_conv);
-
 	group = conv_get_group(conv);
 
 	/* Go through the list of IMs and find one with this group. */
@@ -10004,12 +9963,10 @@
 static void
 conv_placement_by_account(PidginConversation *conv)
 {
-	PurpleConversationType type;
 	GList *wins, *convs;
 	PurpleAccount *account;
 
 	account = purple_conversation_get_account(conv->active_conv);
-	type = purple_conversation_get_type(conv->active_conv);
 
 	/* Go through the list of IMs and find one with this group. */
 	for (wins = pidgin_conv_windows_get_list(); wins != NULL; wins = wins->next) {
--- a/pidgin/gtkdialogs.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/pidgin/gtkdialogs.c	Mon Aug 23 00:52:24 2010 +0000
@@ -1288,7 +1288,7 @@
 
 	purple_debug_info("blist", "Removing '%s' from buddy list.\n", buddy->name);
 	/* TODO - Should remove from blist first... then call purple_account_remove_buddy()? */
-	purple_account_remove_buddy(buddy->account, buddy, group);
+	purple_account_remove_buddy(account, buddy, group);
 	purple_blist_remove_buddy(buddy);
 
 	g_free(name);
--- a/pidgin/gtkft.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/pidgin/gtkft.c	Mon Aug 23 00:52:24 2010 +0000
@@ -112,13 +112,10 @@
 get_xfer_info_strings(PurpleXfer *xfer, char **kbsec, char **time_elapsed,
 					  char **time_remaining)
 {
-	PidginXferUiData *data;
 	double kb_sent, kb_rem;
 	double kbps = 0.0;
 	time_t elapsed, now;
 
-	data = PIDGINXFER(xfer);
-
 	if (xfer->end_time != 0)
 		now = xfer->end_time;
 	else
@@ -1015,7 +1012,6 @@
 {
 	PidginXferUiData *data;
 	char *size_str, *remaining_str;
-	GtkTreeSelection *selection;
 	time_t current_time;
 	GtkTreeIter iter;
 	gboolean valid;
@@ -1066,8 +1062,6 @@
 		g_object_unref(pixbuf);
 	}
 
-	selection = gtk_tree_view_get_selection(GTK_TREE_VIEW(xfer_dialog->tree));
-
 	update_title_progress(dialog);
 	if (xfer == dialog->selected_xfer)
 		update_detailed_info(xfer_dialog, xfer);
--- a/pidgin/gtkimhtml.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/pidgin/gtkimhtml.c	Mon Aug 23 00:52:24 2010 +0000
@@ -1476,10 +1476,8 @@
 static void gtk_imhtml_class_init (GtkIMHtmlClass *klass)
 {
 	GtkWidgetClass *widget_class = (GtkWidgetClass *) klass;
-	GtkObjectClass *object_class;
 	GtkBindingSet *binding_set;
 	GObjectClass   *gobject_class;
-	object_class = (GtkObjectClass*) klass;
 	gobject_class = (GObjectClass*) klass;
 	parent_class = g_type_class_ref(GTK_TYPE_TEXT_VIEW);
 	signals[URL_CLICKED] = g_signal_new("url_clicked",
--- a/pidgin/gtkimhtmltoolbar.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/pidgin/gtkimhtmltoolbar.c	Mon Aug 23 00:52:24 2010 +0000
@@ -1205,9 +1205,7 @@
 /* Boring GTK+ stuff */
 static void gtk_imhtmltoolbar_class_init (GtkIMHtmlToolbarClass *class)
 {
-	GtkObjectClass *object_class;
 	GObjectClass   *gobject_class;
-	object_class = (GtkObjectClass*) class;
 	gobject_class = (GObjectClass*) class;
 	parent_class = g_type_class_ref(GTK_TYPE_HBOX);
 	gobject_class->finalize = gtk_imhtmltoolbar_finalize;
--- a/pidgin/gtkpounce.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/pidgin/gtkpounce.c	Mon Aug 23 00:52:24 2010 +0000
@@ -194,7 +194,6 @@
 {
 	GtkTreeIter iter;
 	PurpleAccount *account;
-	PurplePounceEvent events;
 	gboolean recurring;
 	const char *pouncer;
 	const char *pouncee;
@@ -202,8 +201,6 @@
 
 	account = purple_pounce_get_pouncer(pounce);
 
-	events = purple_pounce_get_events(pounce);
-
 	pixbuf = pidgin_create_prpl_icon(account, PIDGIN_PRPL_ICON_MEDIUM);
 
 	pouncer = purple_account_get_username(account);
--- a/pidgin/gtkroomlist.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/pidgin/gtkroomlist.c	Mon Aug 23 00:52:24 2010 +0000
@@ -362,8 +362,6 @@
 
 	style = grl->tipwindow->style;
 
-	max_text_width = 0;
-
 	max_text_width = MAX(grl->tip_width, grl->tip_name_width);
 	max_width = TOOLTIP_BORDER + SMALL_SPACE + max_text_width + TOOLTIP_BORDER;
 
--- a/pidgin/gtksmiley.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/pidgin/gtksmiley.c	Mon Aug 23 00:52:24 2010 +0000
@@ -520,9 +520,6 @@
 		GtkTreeIter *iter, gpointer data)
 {
 	PurpleSmiley *smiley = NULL;
-	SmileyManager *dialog;
-
-	dialog = (SmileyManager*)data;
 
 	gtk_tree_model_get(model, iter,
 			SMILEY, &smiley,
--- a/pidgin/gtkstatusbox.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/pidgin/gtkstatusbox.c	Mon Aug 23 00:52:24 2010 +0000
@@ -657,7 +657,6 @@
 static void
 pidgin_status_box_refresh(PidginStatusBox *status_box)
 {
-	GtkIconSize icon_size;
 	GtkStyle *style;
 	char aa_color[8];
 	PurpleSavedStatus *saved_status;
@@ -668,8 +667,6 @@
 	gboolean account_status = FALSE;
 	PurpleAccount *acct = (status_box->account) ? status_box->account : status_box->token_status_account;
 
-	icon_size = gtk_icon_size_from_name(PIDGIN_ICON_SIZE_TANGO_EXTRA_SMALL);
-
 	style = gtk_widget_get_style(GTK_WIDGET(status_box));
 	snprintf(aa_color, sizeof(aa_color), "#%02x%02x%02x",
 		 style->text_aa[GTK_STATE_NORMAL].red >> 8,
@@ -969,12 +966,8 @@
 		PurpleSavedStatus *saved = cur->data;
 		const gchar *message;
 		gchar *stripped = NULL;
-		PurpleStatusPrimitive prim;
 		PidginStatusBoxItemType type = PIDGIN_STATUS_BOX_TYPE_POPULAR;
 
-		/* Get an appropriate status icon */
-		prim = purple_savedstatus_get_type(saved);
-
 		if (purple_savedstatus_is_transient(saved))
 		{
 			/*
@@ -1074,17 +1067,13 @@
 					PIDGIN_STATUS_BOX_TYPE_PRIMITIVE, NULL,
 					purple_status_type_get_name(status_type),
 					NULL,
-					GINT_TO_POINTER(purple_status_type_get_primitive(status_type)));
+					GINT_TO_POINTER(prim));
 	}
 }
 
 static void
 pidgin_status_box_regenerate(PidginStatusBox *status_box, gboolean status_changed)
 {
-	GtkIconSize icon_size;
-
-	icon_size = gtk_icon_size_from_name(PIDGIN_ICON_SIZE_TANGO_EXTRA_SMALL);
-
 	/* Unset the model while clearing it */
 	gtk_tree_view_set_model(GTK_TREE_VIEW(status_box->tree_view), NULL);
 	gtk_list_store_clear(status_box->dropdown_store);
--- a/pidgin/gtkutils.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/pidgin/gtkutils.c	Mon Aug 23 00:52:24 2010 +0000
@@ -680,7 +680,6 @@
 create_protocols_menu(const char *default_proto_id)
 {
 	AopMenu *aop_menu = NULL;
-	PurplePluginProtocolInfo *prpl_info;
 	PurplePlugin *plugin;
 	GdkPixbuf *pixbuf = NULL;
 	GtkSizeGroup *sg;
@@ -702,7 +701,6 @@
 		 p = p->next, i++) {
 
 		plugin = (PurplePlugin *)p->data;
-		prpl_info = PURPLE_PLUGIN_PROTOCOL_INFO(plugin);
 
 		if (gtalk_name && strcmp(gtalk_name, plugin->info->name) < 0) {
 			char *filename = g_build_filename(DATADIR, "pixmaps", "pidgin", "protocols",
@@ -784,8 +782,6 @@
 	sg = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
 
 	for (p = list, i = 0; p != NULL; p = p->next, i++) {
-		PurplePlugin *plugin;
-
 		if (show_all)
 			account = (PurpleAccount *)p->data;
 		else {
@@ -799,8 +795,6 @@
 			continue;
 		}
 
-		plugin = purple_find_prpl(purple_account_get_protocol_id(account));
-
 		pixbuf = pidgin_create_prpl_icon(account, PIDGIN_PRPL_ICON_SMALL);
 
 		if (pixbuf) {
@@ -2790,14 +2784,13 @@
 
 
 gboolean pidgin_gdk_pixbuf_is_opaque(GdkPixbuf *pixbuf) {
-	int width, height, rowstride, i;
+	int height, rowstride, i;
 	unsigned char *pixels;
 	unsigned char *row;
 
 	if (!gdk_pixbuf_get_has_alpha(pixbuf))
 		return TRUE;
 
-	width = gdk_pixbuf_get_width (pixbuf);
 	height = gdk_pixbuf_get_height (pixbuf);
 	rowstride = gdk_pixbuf_get_rowstride (pixbuf);
 	pixels = gdk_pixbuf_get_pixels (pixbuf);
--- a/pidgin/plugins/notify.c	Sun Aug 22 22:15:38 2010 +0000
+++ b/pidgin/plugins/notify.c	Mon Aug 23 00:52:24 2010 +0000
@@ -303,7 +303,6 @@
 attach_signals(PurpleConversation *conv)
 {
 	PidginConversation *gtkconv = NULL;
-	PidginWindow *gtkwin = NULL;
 	GSList *imhtml_ids = NULL, *entry_ids = NULL;
 	guint id;
 
@@ -313,8 +312,6 @@
 		return 0;
 	}
 
-	gtkwin  = gtkconv->win;
-
 	if (purple_prefs_get_bool("/plugins/gtk/X11/notify/notify_focus")) {
 		/* TODO should really find a way to make this work no matter
 		 * where the focus is inside the conv window, without having
@@ -358,13 +355,11 @@
 detach_signals(PurpleConversation *conv)
 {
 	PidginConversation *gtkconv = NULL;
-	PidginWindow *gtkwin = NULL;
 	GSList *ids = NULL, *l;
 
 	gtkconv = PIDGIN_CONVERSATION(conv);
 	if (!gtkconv)
 		return;
-	gtkwin  = gtkconv->win;
 
 	ids = purple_conversation_get_data(conv, "notify-imhtml-signals");
 	for (l = ids; l != NULL; l = l->next)
@@ -650,7 +645,6 @@
 apply_method()
 {
 	GList *convs;
-	PidginWindow *purplewin = NULL;
 
 	for (convs = purple_get_conversations(); convs != NULL;
 	     convs = convs->next) {
@@ -659,7 +653,6 @@
 		/* remove notifications */
 		unnotify(conv, FALSE);
 
-		purplewin = PIDGIN_CONVERSATION(conv)->win;
 		if (GPOINTER_TO_INT(purple_conversation_get_data(conv, "notify-message-count")) != 0)
 			/* reattach appropriate notifications */
 			notify(conv, FALSE);