pidgin: 7df8a2a7: Fix a crash when sending OIMs on MSN. Th...
qulogic at pidgin.im
qulogic at pidgin.im
Sat Oct 24 03:55:38 EDT 2009
-----------------------------------------------------------------
Revision: 7df8a2a726d522f0120b6cec62f683503591a040
Ancestor: 5f34ca8ecb9f3ed36f1b66300ecfd2197e0e8243
Author: qulogic at pidgin.im
Date: 2009-10-24T07:53:02
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/7df8a2a726d522f0120b6cec62f683503591a040
Modified files:
ChangeLog libpurple/protocols/msn/oim.c
ChangeLog:
Fix a crash when sending OIMs on MSN. The callback function used after
updating the token was incorrectly defined with void return and could be
called again after the timeout (as would normally happen for timeouts that
return TRUE).
Thanks to Sadrul for getting a good backtrace and finding the real cause.
Fixes #8155.
-------------- next part --------------
============================================================
--- ChangeLog f187f7d07e248381c65954c1809e5490292337da
+++ ChangeLog 3d7baf88a34722016605c49c3156dce77cff6d6a
@@ -16,6 +16,7 @@ version 2.6.4 (??/??/20??):
* Fix a random crash that might occur when idle.
* Fix more FQY 240 connection errors.
* Fix a crash that could occur when adding a buddy.
+ * Fix an occasional crash when sending message to an offline user.
XMPP:
* Users connecting to Google Talk now have an "Initiate Chat" context menu
============================================================
--- libpurple/protocols/msn/oim.c f8cfdf73d17aa75cb4131dc5b1596820aec36ac8
+++ libpurple/protocols/msn/oim.c 4e3b96699692c8b11626bb21613d2928eac7db58
@@ -153,7 +153,7 @@ typedef struct _MsnOimRequestData {
gpointer cb_data;
} MsnOimRequestData;
-static void msn_oim_request_helper(MsnOimRequestData *data);
+static gboolean msn_oim_request_helper(MsnOimRequestData *data);
static void
msn_oim_request_cb(MsnSoapMessage *request, MsnSoapMessage *response,
@@ -202,7 +202,7 @@ msn_oim_request_cb(MsnSoapMessage *reque
g_free(data);
}
-static void
+static gboolean
msn_oim_request_helper(MsnOimRequestData *data)
{
MsnSession *session = data->oim->session;
@@ -224,13 +224,13 @@ msn_oim_request_helper(MsnOimRequestData
const char *msn_p;
token = msn_nexus_get_token(session->nexus, MSN_AUTH_MESSENGER_WEB);
- g_return_if_fail(token != NULL);
+ g_return_val_if_fail(token != NULL, FALSE);
msn_t = g_hash_table_lookup(token, "t");
msn_p = g_hash_table_lookup(token, "p");
- g_return_if_fail(msn_t != NULL);
- g_return_if_fail(msn_p != NULL);
+ g_return_val_if_fail(msn_t != NULL, FALSE);
+ g_return_val_if_fail(msn_p != NULL, FALSE);
passport = xmlnode_get_child(data->body, "Header/PassportCookie");
xml_t = xmlnode_get_child(passport, "t");
@@ -248,6 +248,8 @@ msn_oim_request_helper(MsnOimRequestData
msn_soap_message_new(data->action, xmlnode_copy(data->body)),
data->host, data->url, FALSE,
msn_oim_request_cb, data);
+
+ return FALSE;
}
More information about the Commits
mailing list