cpw.malu.xmpp.jingle_ft: 29b0a150: Removed some more unused code

malu at pidgin.im malu at pidgin.im
Tue Oct 6 16:36:23 EDT 2009


-----------------------------------------------------------------
Revision: 29b0a1502d9e11ff8c018b5f1229ea01ef52ff5f
Ancestor: 4ee0e642066c91e31509a643909b231b677f7f81
Author: malu at pidgin.im
Date: 2009-10-06T20:33:38
Branch: im.pidgin.cpw.malu.xmpp.jingle_ft
URL: http://d.pidgin.im/viewmtn/revision/info/29b0a1502d9e11ff8c018b5f1229ea01ef52ff5f

Modified files:
        libpurple/protocols/jabber/jingle/file-transfer.c

ChangeLog: 

Removed some more unused code
Fix some compiler warnings (function signatures and unused variables)

-------------- next part --------------
============================================================
--- libpurple/protocols/jabber/jingle/file-transfer.c	4a074222080a05a3471425c2ebd20b1e639686ae
+++ libpurple/protocols/jabber/jingle/file-transfer.c	a07453470da0fc4287ea8bb1d02d17d4c68f7e6f
@@ -196,21 +196,6 @@ static void
 }
 
 static void
-jingle_file_transfer_success(JingleContent *content)
-{
-	PurpleXfer *xfer = JINGLE_FT_GET_PRIVATE(JINGLE_FT(content))->xfer;
-	JingleSession *session = jingle_content_get_session(content);
-	
-	purple_debug_info("jingle-ft", "transfer received successful!\n");
-	if (xfer) {
-		purple_xfer_set_completed(xfer, TRUE);
-		purple_xfer_end(xfer);
-	}
-
-	g_object_unref(session);
-}
-
-static void
 jingle_file_transfer_ibb_end(JingleContent *content)
 {
 	PurpleXfer *xfer = JINGLE_FT_GET_PRIVATE(JINGLE_FT(content))->xfer;
@@ -226,8 +211,8 @@ jingle_file_transfer_ibb_end(JingleConte
 	}
 }
 
-static gsize
-jingle_file_transfer_ibb_write(const guchar *buffer, gsize len, PurpleXfer *xfer)
+static gssize
+jingle_file_transfer_ibb_write(const guchar *buffer, size_t len, PurpleXfer *xfer)
 {
 	JingleContent *content = (JingleContent *) xfer->data;
 	JingleTransport *transport = jingle_content_get_transport(content);
@@ -277,7 +262,7 @@ jingle_file_transfer_ibb_data_recv_callb
 	}
 }
 
-static gsize
+static gssize
 jingle_file_transfer_ibb_read(guchar **out_buffer, PurpleXfer *xfer)
 {
 	JingleContent *content = (JingleContent *) xfer->data;
@@ -642,7 +627,6 @@ jingle_file_transfer_parse_internal(xmln
 jingle_file_transfer_parse_internal(xmlnode *ft)
 {
 	JingleContent *content = parent_class->parse(ft);
-	xmlnode *description = xmlnode_get_child(ft, "description");
 	purple_debug_info("jingle-ft", "ft parse\n");
 	return content;
 }
@@ -671,15 +655,12 @@ jingle_file_transfer_handle_action_inter
 	switch (action) {
 		case JINGLE_SESSION_ACCEPT: {
 			JingleSession *session = jingle_content_get_session(content);
-			xmlnode *description = xmlnode_get_child(xmlcontent, "description");
 			JingleTransport *transport = jingle_content_get_transport(content);
 			PurpleXfer *xfer = 
 				JINGLE_FT_GET_PRIVATE(JINGLE_FT(content))->xfer;
 			
 			/* do stuff here, start the transfer, etc... */
 			if (JINGLE_IS_IBB(transport)) {
-				JingleFT *ft = JINGLE_FT(content);
-
 				/* send first data */
 				purple_xfer_set_write_fnc(xfer, jingle_file_transfer_ibb_write);
 				purple_xfer_start(xfer, -1, NULL, 0);
@@ -738,8 +719,6 @@ jingle_file_transfer_handle_action_inter
 					const gchar *sid = 
 						xmlnode_get_attrib(xmlnode_get_child(xmlcontent, 
 							"transport"), "sid");
-					const gchar *filename = 
-						purple_xfer_get_local_filename(xfer);
 					jingle_ibb_create_session(ibb, content, sid, who);
 					JINGLE_FT(content)->priv->ibb_buffer =
 						purple_circ_buffer_new(jingle_ibb_get_block_size(ibb));
@@ -840,13 +819,11 @@ jingle_file_transfer_handle_action_inter
 		}
 		case JINGLE_TRANSPORT_REPLACE: {
 			JingleSession *session = jingle_content_get_session(content);
-			xmlnode *xmltransport = xmlnode_get_child(xmlcontent, "transport");
 			const gchar *sid = 
 				xmlnode_get_attrib(xmlnode_get_child(xmlcontent, 
 					"transport"), "sid");
 			gchar *who = jingle_session_get_remote_jid(session);
 			PurpleXfer *xfer = JINGLE_FT(content)->priv->xfer;
-			const gchar *filename = purple_xfer_get_local_filename(xfer);
 			JingleTransport *new_transport = 
 				jingle_content_get_pending_transport(content);
 			


More information about the Commits mailing list