cpw.malu.xmpp.google_ft: f1792777: don't crash when receiving a session act...
malu at pidgin.im
malu at pidgin.im
Tue Sep 14 16:40:26 EDT 2010
----------------------------------------------------------------------
Revision: f1792777d16a5e521697a716d38847ce4ef2521d
Parent: c58cf9475b309633c6bd3199d5fe6246b22db185
Author: malu at pidgin.im
Date: 09/14/10 16:38:04
Branch: im.pidgin.cpw.malu.xmpp.google_ft
URL: http://d.pidgin.im/viewmtn/revision/info/f1792777d16a5e521697a716d38847ce4ef2521d
Changelog:
don't crash when receiving a session action for which the current session has no callback
Changes against parent c58cf9475b309633c6bd3199d5fe6246b22db185
patched libpurple/protocols/jabber/google/google_session.c
-------------- next part --------------
============================================================
--- libpurple/protocols/jabber/google/google_session.c ef29beb85ad3f646f5da2068d41b7f1f19817180
+++ libpurple/protocols/jabber/google/google_session.c 27a96dbf91e538b91c5042983cbd2bb94b3b2c9b
@@ -94,25 +94,29 @@ google_session_handle_candidates(JabberS
static void
google_session_handle_candidates(JabberStream *js, GoogleSession *session, xmlnode *sess, const char *iq_id)
{
- session->handle_candidates_cb(js, session, sess, iq_id);
+ if (session->handle_candidates_cb)
+ session->handle_candidates_cb(js, session, sess, iq_id);
}
static void
google_session_handle_accept(JabberStream *js, GoogleSession *session, xmlnode *sess, const char *iq_id)
{
- session->handle_accept_cb(js, session, sess, iq_id);
+ if (session->handle_accept_cb)
+ session->handle_accept_cb(js, session, sess, iq_id);
}
static void
google_session_handle_reject(JabberStream *js, GoogleSession *session, xmlnode *sess)
{
- session->handle_reject_cb(js, session, sess);
+ if (session->handle_reject_cb)
+ session->handle_reject_cb(js, session, sess);
}
static void
google_session_handle_terminate(JabberStream *js, GoogleSession *session, xmlnode *sess)
{
- session->handle_terminate_cb(js, session, sess);
+ if (session->handle_terminate_cb)
+ session->handle_terminate_cb(js, session, sess);
}
More information about the Commits
mailing list