changeset 28461:6100cb11bae8

Parse online presence from yahoo buddies after going online on MSN.
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Fri, 30 Oct 2009 01:32:28 +0000
parents 9c6495646694
children 61fd49ad0def
files libpurple/protocols/msn/notification.c
diffstat 1 files changed, 11 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/protocols/msn/notification.c	Wed Oct 28 00:35:32 2009 +0000
+++ b/libpurple/protocols/msn/notification.c	Fri Oct 30 01:32:28 2009 +0000
@@ -1068,7 +1068,17 @@
 		/* Where'd this come from? */
 		return;
 
-	if (cmd->param_count == 7) {
+	if (cmd->param_count == 8) {
+		/* Yahoo! Buddy, looks like */
+		networkid = atoi(cmd->params[3]);
+		friendly = g_strdup(purple_url_decode(cmd->params[4]));
+		clientid = strtoul(cmd->params[5], NULL, 10);
+
+		/* cmd->params[7] seems to be a URL to a Yahoo! icon:
+				https://sec.yimg.com/i/us/nt/b/purpley.1.0.png
+		   ... and it's purple, HAH!
+		*/
+	} else if (cmd->param_count == 7) {
 		/* MSNP14+ with Display Picture object */
 		networkid = atoi(cmd->params[3]);
 		friendly = g_strdup(purple_url_decode(cmd->params[4]));