soc.2010.msn-tlc: 43b3034b: Allow temporary SlpMessages so we can ge...
masca at cpw.pidgin.im
masca at cpw.pidgin.im
Tue Jun 8 18:25:41 EDT 2010
-----------------------------------------------------------------
Revision: 43b3034bb9b038e1fcdd89ca9a8eb428ff33cadb
Ancestor: ece60cf5e8864f651e02e8b50350ca5c6cd659ca
Author: masca at cpw.pidgin.im
Date: 2010-06-08T01:45:49
Branch: im.pidgin.soc.2010.msn-tlc
URL: http://d.pidgin.im/viewmtn/revision/info/43b3034bb9b038e1fcdd89ca9a8eb428ff33cadb
Modified files:
libpurple/protocols/msn/slpmsg.c
libpurple/protocols/msn/slpmsg.h
ChangeLog:
Allow temporary SlpMessages so we can get slp specific code from MsnMessage.
-------------- next part --------------
============================================================
--- libpurple/protocols/msn/slpmsg.c 95fa4210f3a853ca9229a205cf3dcd909ed61c8e
+++ libpurple/protocols/msn/slpmsg.c 04c5f7eb550f0eb0e564ed29aa64f00849048a4e
@@ -42,10 +42,13 @@ msn_slpmsg_new(MsnSlpLink *slplink)
if (purple_debug_is_verbose())
purple_debug_info("msn", "slpmsg new (%p)\n", slpmsg);
- slpmsg->slplink = slplink;
+ if (slplink) {
+ slpmsg->slplink = slplink;
- slplink->slp_msgs =
- g_list_append(slplink->slp_msgs, slpmsg);
+ slplink->slp_msgs =
+ g_list_append(slplink->slp_msgs, slpmsg);
+ } else
+ slpmsg->slplink = NULL;
slpmsg->header = NULL;
slpmsg->footer = NULL;
============================================================
--- libpurple/protocols/msn/slpmsg.h 13a2040810f261b2d1aa93fab3941c23f9997db2
+++ libpurple/protocols/msn/slpmsg.h 85589294b2abbca2e5d5f311b0571772b91398b9
@@ -88,6 +88,7 @@ struct _MsnSlpMessage
* Creates a new slp message
*
* @param slplink The slplink through which this slp message will be sent.
+ * If it's set to NULL, it is a temporary SlpMessage.
* @return The created slp message.
*/
MsnSlpMessage *msn_slpmsg_new(MsnSlpLink *slplink);
More information about the Commits
mailing list