pidgin: 8ae64977: Make msn_dc_fallback_to_p2p non-static, ...
qulogic at pidgin.im
qulogic at pidgin.im
Fri May 21 18:03:52 EDT 2010
-----------------------------------------------------------------
Revision: 8ae64977f9f373b826ea4c74134742ade5fac8a4
Ancestor: 9b484f7e3599dd3e85b6c482596391fdb2c21194
Author: qulogic at pidgin.im
Date: 2010-05-05T07:26:57
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/8ae64977f9f373b826ea4c74134742ade5fac8a4
Modified files:
libpurple/protocols/msn/directconn.c
libpurple/protocols/msn/directconn.h
ChangeLog:
Make msn_dc_fallback_to_p2p non-static, and remove some old code.
-------------- next part --------------
============================================================
--- libpurple/protocols/msn/directconn.c d0a677794aaedadd3921bf99597cb306f1241665
+++ libpurple/protocols/msn/directconn.c b36736e9e052e5baea1f0274133703968267c4a7
@@ -313,11 +313,10 @@ msn_dc_send_ok(MsnDirectConn *dc)
msn_slplink_send_queued_slpmsgs(dc->slpcall->slplink);
}
-static void
+void
msn_dc_fallback_to_p2p(MsnDirectConn *dc)
{
MsnSlpCall *slpcall;
- PurpleXfer *xfer;
purple_debug_info("msn", "msn_dc_try_fallback_to_p2p %p\n", dc);
@@ -326,46 +325,9 @@ msn_dc_fallback_to_p2p(MsnDirectConn *dc
slpcall = dc->slpcall;
g_return_if_fail(slpcall != NULL);
- xfer = slpcall->xfer;
- g_return_if_fail(xfer != NULL);
-
msn_dc_destroy(dc);
msn_slpcall_session_init(slpcall);
-
- /*
- switch (purple_xfer_get_status(xfer)) {
- case PURPLE_XFER_STATUS_NOT_STARTED:
- case PURPLE_XFER_STATUS_ACCEPTED:
- msn_slpcall_session_init(slpcall);
- break;
-
- case PURPLE_XFER_STATUS_STARTED:
- slpcall->session_init_cb = NULL;
- slpcall->end_cb = NULL;
- slpcall->progress_cb = NULL;
- slpcall->cb = NULL;
-
- if (fail_local)
- purple_xfer_cancel_local(xfer);
- else
- purple_xfer_cancel_remote(xfer);
- break;
-
- default:
- slpcall->session_init_cb = NULL;
- slpcall->end_cb = NULL;
- slpcall->progress_cb = NULL;
- slpcall->cb = NULL;
-
- if (fail_local)
- purple_xfer_cancel_local(xfer);
- else
- purple_xfer_cancel_remote(xfer);
-
- break;
- }
- */
}
static void
============================================================
--- libpurple/protocols/msn/directconn.h d648293b0215b8c55de9f7e63040aa9d4758b6f4
+++ libpurple/protocols/msn/directconn.h 7560777e15c1e4dc878a261b8b6f005065772f66
@@ -55,6 +55,7 @@ typedef enum
typedef enum
{
+ DC_NONCE_UNKNOWN, /**< Invalid scheme */
DC_NONCE_PLAIN, /**< No hashing */
DC_NONCE_SHA1 /**< First 16 bytes of SHA1 of nonce */
@@ -136,6 +137,13 @@ msn_dc_destroy(MsnDirectConn *dc);
msn_dc_destroy(MsnDirectConn *dc);
/*
+ * Fallback to switchboard connection. Used when neither side is able to
+ * create a listening socket.
+ */
+void
+msn_dc_fallback_to_p2p(MsnDirectConn *dc);
+
+/*
* Increases the slpcall counter in DC. The direct connection remains open
* until all slpcalls using it are destroyed.
*/
More information about the Commits
mailing list