gobjectification: 5ca1d85f: Fix a few more warnings, some of which w...

qulogic at pidgin.im qulogic at pidgin.im
Tue Jun 9 01:01:13 EDT 2009


-----------------------------------------------------------------
Revision: 5ca1d85f77df797f7890407299e2a001b831669f
Ancestor: 4ba4b224fe488af8e48d3d528c39801d243b0de2
Author: qulogic at pidgin.im
Date: 2009-06-09T04:54:40
Branch: im.pidgin.gobjectification
URL: http://d.pidgin.im/viewmtn/revision/info/5ca1d85f77df797f7890407299e2a001b831669f

Modified files:
        libpurple/account.c libpurple/protocols/bonjour/bonjour_ft.c
        libpurple/protocols/bonjour/jabber.c
        libpurple/protocols/gg/gg.c libpurple/protocols/irc/msgs.c
        libpurple/protocols/msn/msg.c
        libpurple/protocols/myspace/myspace.c

ChangeLog: 

Fix a few more warnings, some of which were hiding real errors.

-------------- next part --------------
============================================================
--- libpurple/account.c	f7dbc8f3e8becd072b218a156b5540cd06f16a05
+++ libpurple/account.c	6147d3da94bd1399e5f47e64bb7ddc87d393d1da
@@ -2355,6 +2355,7 @@ gboolean purple_account_supports_offline
 	return prpl_info->offline_message(buddy);
 }
 
+#if 0
 static void
 signed_on_cb(PurpleConnection *gc,
              gpointer unused)
@@ -2362,6 +2363,7 @@ signed_on_cb(PurpleConnection *gc,
 	PurpleAccount *account = purple_connection_get_account(gc);
 	purple_account_clear_current_error(account);
 }
+#endif
 
 static void
 set_current_error(PurpleAccount *account,
@@ -2392,6 +2394,7 @@ set_current_error(PurpleAccount *account
 	g_free(old_err);
 }
 
+#if 0
 static void
 connection_error_cb(PurpleConnection *gc,
                     PurpleConnectionError type,
@@ -2413,6 +2416,7 @@ connection_error_cb(PurpleConnection *gc
 
 	set_current_error(account, err);
 }
+#endif
 
 const PurpleConnectionErrorInfo *
 purple_account_get_current_error(PurpleAccount *account)
============================================================
--- libpurple/protocols/bonjour/bonjour_ft.c	d465e3c51a1aefa72c552efbf7499c9ccca2eab2
+++ libpurple/protocols/bonjour/bonjour_ft.c	784f1ebc42d4a0eb75c0c19d5abdf08a39f3bdec
@@ -844,7 +844,6 @@ bonjour_bytestreams_connect(PurpleXfer *
 bonjour_bytestreams_connect(PurpleXfer *xfer, PurpleBuddy *pb)
 {
 	PurpleCipher *cipher;
-	PurpleAccount *account = NULL;
 	XepXfer *xf;
 	char dstaddr[41];
 	unsigned char hashval[20];
============================================================
--- libpurple/protocols/bonjour/jabber.c	4ba5871c21afb88f5ac052fd2d1460e869a0b079
+++ libpurple/protocols/bonjour/jabber.c	bf1e7f032380053dd0928ecfe83e0a7a8e1ed050
@@ -802,7 +802,7 @@ bonjour_jabber_conv_match_by_name(Bonjou
 	g_return_if_fail(bconv->pb == NULL);
 
 	pb = purple_find_buddy(bconv->account, bconv->buddy_name);
-	if (pb && (bb = purple_object_get_protocol_data(pb))) {
+	if (pb && (bb = purple_object_get_protocol_data(PURPLE_OBJECT(pb)))) {
 		const char *ip;
 		GSList *tmp = bb->ips;
 
============================================================
--- libpurple/protocols/gg/gg.c	5b34741be6167dfb0c4dc144f52086b216e3eff3
+++ libpurple/protocols/gg/gg.c	e74d60055877ba5e305d90a1a2cd1ee13d0565c8
@@ -1722,7 +1722,7 @@ static GList *ggp_blist_node_menu(Purple
 		return NULL;
 
 	account = purple_buddy_get_account((PurpleBuddy *) node);
-	info = purple_object_get_protocol_data(purple_account_get_connection(account));
+	info = purple_object_get_protocol_data(PURPLE_OBJECT(purple_account_get_connection(account)));
 	if (info->chats) {
 		act = purple_menu_action_new(_("Add to chat"),
 			PURPLE_CALLBACK(ggp_bmenu_add_to_chat),
============================================================
--- libpurple/protocols/irc/msgs.c	57ab14705c51779bbb78ad59121b12805fa64f0a
+++ libpurple/protocols/irc/msgs.c	6fe2e00102ab6ac9fab40a133505d80c7c3b74b1
@@ -34,7 +34,9 @@ static char *irc_mask_userhost(const cha
 
 static char *irc_mask_nick(const char *mask);
 static char *irc_mask_userhost(const char *mask);
+#if 0
 static void irc_chat_remove_buddy(PurpleConversation *convo, char *data[2]);
+#endif
 static void irc_buddy_status(char *name, struct irc_buddy *ib, struct irc_conn *irc);
 static void irc_connected(struct irc_conn *irc, const char *nick);
 
@@ -60,6 +62,7 @@ static char *irc_mask_userhost(const cha
 	return g_strdup(strchr(mask, '!') + 1);
 }
 
+#if 0
 static void irc_chat_remove_buddy(PurpleConversation *convo, char *data[2])
 {
 	char *message, *stripped;
@@ -73,6 +76,7 @@ static void irc_chat_remove_buddy(Purple
 
 	g_free(message);
 }
+#endif
 
 static void irc_connected(struct irc_conn *irc, const char *nick)
 {
@@ -935,7 +939,9 @@ void irc_msg_nick(struct irc_conn *irc, 
 {
 	PurpleConnection *gc = purple_account_get_connection(irc->account);
 	PurpleConversation *conv;
+#if 0
 	GSList *chats;
+#endif
 	char *nick = irc_mask_nick(from);
 
 	irc->nickused = FALSE;
============================================================
--- libpurple/protocols/msn/msg.c	8a255c717ddbe76eea31cbb902e438f26a2bc111
+++ libpurple/protocols/msn/msg.c	b8b27367fd1cec6de5ba7d5440dc0c675bb6253d
@@ -961,13 +961,13 @@ msn_datacast_msg(MsnCmdProc *cmdproc, Ms
 			if (swboard->current_users > 1 ||
 				((swboard->conv != NULL) &&
 				 purple_conversation_get_type(swboard->conv) == PURPLE_CONV_TYPE_CHAT))
-				purple_prpl_got_attention_in_chat(account, swboard->chat_id, user, MSN_NUDGE);
+				purple_prpl_got_attention_in_chat(gc, swboard->chat_id, user, MSN_NUDGE);
 
 			else
-				purple_prpl_got_attention(account, user, MSN_NUDGE);
+				purple_prpl_got_attention(gc, user, MSN_NUDGE);
 
 		} else {
-			purple_prpl_got_attention(account, user, MSN_NUDGE);
+			purple_prpl_got_attention(gc, user, MSN_NUDGE);
 		}
 
 	} else if (!strcmp(id, "2")) {
============================================================
--- libpurple/protocols/myspace/myspace.c	ad0f645b123a6a70a8bfc9f6002b7506d869a98e
+++ libpurple/protocols/myspace/myspace.c	464d24f954a8834daaf72c39de1e27646d36ede6
@@ -443,7 +443,7 @@ msim_tooltip_text(PurpleBuddy *buddy, Pu
 		PurpleAccount *account = purple_buddy_get_account(buddy);
 		PurpleConnection *gc = purple_account_get_connection(account);
  
-		session = (MsimSession *)purple_object_get_protocol_data(PURPLE_OBJECT(purple_account_get_connection(buddy->account)));
+		session = (MsimSession *)purple_object_get_protocol_data(PURPLE_OBJECT(gc));
 
 		g_return_if_fail(MSIM_SESSION_VALID(session));
 


More information about the Commits mailing list