diff src/protocols/msn/notification.c @ 5506:4f72b611f0ee

[gaim-migrate @ 5905] A few changes here. - Messages now have reference counting. - There's a message queue API in servconn. This was needed for times when we have a message but need further information from a command before processing it, like initial e-mail notifications. - As a result of the two above, we now have initial e-mail notifications again! committer: Tailor Script <tailor@pidgin.im>
author Christian Hammond <chipx86@chipx86.com>
date Sun, 25 May 2003 09:04:32 +0000
parents cce2d7868c78
children 2a57266df5f6
line wrap: on
line diff
--- a/src/protocols/msn/notification.c	Sat May 24 19:15:58 2003 +0000
+++ b/src/protocols/msn/notification.c	Sun May 25 09:04:32 2003 +0000
@@ -1139,7 +1139,7 @@
  * Message Types
  **************************************************************************/
 static gboolean
-__profile_msg(MsnServConn *servconn, const MsnMessage *msg)
+__profile_msg(MsnServConn *servconn, MsnMessage *msg)
 {
 	MsnSession *session = servconn->session;
 	const char *value;
@@ -1162,7 +1162,7 @@
 }
 
 static gboolean
-__initial_email_msg(MsnServConn *servconn, const MsnMessage *msg)
+__initial_email_msg(MsnServConn *servconn, MsnMessage *msg)
 {
 	MsnSession *session = servconn->session;
 	struct gaim_connection *gc = session->account->gc;
@@ -1176,6 +1176,9 @@
 
 	if (session->passport_info.file == NULL) {
 		msn_servconn_send_command(servconn, "URL", "INBOX");
+
+		msn_servconn_queue_message(servconn, "URL", msg);
+
 		return TRUE;
 	}
 
@@ -1193,7 +1196,7 @@
 }
 
 static gboolean
-__email_msg(MsnServConn *servconn, const MsnMessage *msg)
+__email_msg(MsnServConn *servconn, MsnMessage *msg)
 {
 	MsnSession *session = servconn->session;
 	struct gaim_connection *gc = session->account->gc;
@@ -1207,6 +1210,9 @@
 
 	if (session->passport_info.file == NULL) {
 		msn_servconn_send_command(servconn, "URL", "INBOX");
+
+		msn_servconn_queue_message(servconn, "URL", msg);
+
 		return TRUE;
 	}
 
@@ -1229,7 +1235,7 @@
 }
 
 static gboolean
-__system_msg(MsnServConn *servconn, const MsnMessage *msg)
+__system_msg(MsnServConn *servconn, MsnMessage *msg)
 {
 	GHashTable *table;
 	const char *type_s;