pidgin: 328de073: I think it's more accurate to say that a...

qulogic at pidgin.im qulogic at pidgin.im
Wed May 26 21:00:56 EDT 2010


-----------------------------------------------------------------
Revision: 328de073576a813f15f447a48d6ecb13306ccc0f
Ancestor: 969bc99e0a442f93b393fc5d4b42b1b4d2134832
Author: qulogic at pidgin.im
Date: 2010-05-26T23:20:18
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/328de073576a813f15f447a48d6ecb13306ccc0f

Modified files:
        libpurple/protocols/msn/directconn.c
        libpurple/protocols/msn/directconn.h
        libpurple/protocols/msn/slp.c

ChangeLog: 

I think it's more accurate to say that a DC is a P2P transfer, so if that
fails, we're falling back to SB, not P2P.

-------------- next part --------------
============================================================
--- libpurple/protocols/msn/directconn.c	21df6e8a863a710fb6c63347b6d80a863faf1071
+++ libpurple/protocols/msn/directconn.c	a01f57fef4de034cb9fae5b9aab70dfad4ae8a7b
@@ -314,13 +314,13 @@ void
 }
 
 void
-msn_dc_fallback_to_p2p(MsnDirectConn *dc)
+msn_dc_fallback_to_sb(MsnDirectConn *dc)
 {
 	MsnSlpLink *slplink;
 	MsnSlpCall *slpcall;
 	GQueue *queue = NULL;
 
-	purple_debug_info("msn", "msn_dc_try_fallback_to_p2p %p\n", dc);
+	purple_debug_info("msn", "msn_dc_fallback_to_sb %p\n", dc);
 
 	g_return_if_fail(dc != NULL);
 
@@ -677,7 +677,7 @@ msn_dc_recv_cb(gpointer data, gint fd, P
 		purple_debug_warning("msn", "msn_dc_recv_cb: recv error\n");
 
 		if(dc->state != DC_STATE_ESTABLISHED)
-			msn_dc_fallback_to_p2p(dc);
+			msn_dc_fallback_to_sb(dc);
 		else
 			msn_dc_destroy(dc);
 		return;
@@ -687,7 +687,7 @@ msn_dc_recv_cb(gpointer data, gint fd, P
 		purple_debug_info("msn", "msn_dc_recv_cb: recv EOF\n");
 
 		if(dc->state != DC_STATE_ESTABLISHED)
-			msn_dc_fallback_to_p2p(dc);
+			msn_dc_fallback_to_sb(dc);
 		else
 			msn_dc_destroy(dc);
 		return;
@@ -720,8 +720,8 @@ msn_dc_recv_cb(gpointer data, gint fd, P
 			return;
 
 		case DC_PROCESS_FALLBACK:
-			purple_debug_warning("msn", "msn_dc_recv_cb: packet processing error, fall back to p2p\n");
-			msn_dc_fallback_to_p2p(dc);
+			purple_debug_warning("msn", "msn_dc_recv_cb: packet processing error, fall back to SB\n");
+			msn_dc_fallback_to_sb(dc);
 			return;
 
 		}
@@ -822,7 +822,7 @@ msn_dc_incoming_connection_timeout_cb(gp
 	}
 
 	dc->connect_timeout_handle = 0;
-	msn_dc_fallback_to_p2p(dc);
+	msn_dc_fallback_to_sb(dc);
 
 	return FALSE;
 }
@@ -870,7 +870,7 @@ msn_dc_outgoing_connection_timeout_cb(gp
 		} else {
 			/*
 			 * Connection failed
-			 * Fall back to P2P transfer
+			 * Fall back to SB transfer
 			 */
 			msn_dc_outgoing_connection_timeout_cb(dc);
 		}
@@ -878,9 +878,9 @@ msn_dc_outgoing_connection_timeout_cb(gp
 	} else {
 		/*
 		 * Both internal and external connection attempts failed.
-		 * Fall back to p2p transfer.
+		 * Fall back to SB transfer.
 		 */
-		msn_dc_fallback_to_p2p(dc);
+		msn_dc_fallback_to_sb(dc);
 	}
 
 	return FALSE;
============================================================
--- libpurple/protocols/msn/directconn.h	8b56d2d2e95dd59e247a371807a5889e107e2a38
+++ libpurple/protocols/msn/directconn.h	4e9d959f17b7bf137c0ac9ecca10912b99d3888b
@@ -145,7 +145,7 @@ void
  * create a listening socket.
  */
 void
-msn_dc_fallback_to_p2p(MsnDirectConn *dc);
+msn_dc_fallback_to_sb(MsnDirectConn *dc);
 
 /*
  * Increases the slpcall counter in DC. The direct connection remains open
============================================================
--- libpurple/protocols/msn/slp.c	5811132cf3d10acbaf4cb92b2bfc3678351d7cfc
+++ libpurple/protocols/msn/slp.c	b0a0e9d9da7f607dd4833c7e1a63a315f5d8118e
@@ -360,7 +360,7 @@ msn_slp_process_transresp(MsnSlpCall *sl
 
 			} else {
 				/* We weren't able to create a listener either. Use SB. */
-				msn_dc_fallback_to_p2p(dc);
+				msn_dc_fallback_to_sb(dc);
 			}
 
 		} else {
@@ -939,7 +939,7 @@ got_error(MsnSlpCall *slpcall,
 	if (type && !strcmp(type, "application/x-msnmsgr-transreqbody")) {
 		MsnDirectConn *dc = slpcall->slplink->dc;
 		if (dc) {
-			msn_dc_fallback_to_p2p(dc);
+			msn_dc_fallback_to_sb(dc);
 			return;
 		}
 	}


More information about the Commits mailing list