cpw.qulogic.msn: 95fe6271: When receiving an MSN OUT, don't try to ...

qulogic at pidgin.im qulogic at pidgin.im
Tue Jul 8 22:26:13 EDT 2008


-----------------------------------------------------------------
Revision: 95fe62719d362e8857a89e906a9008305e31dd5e
Ancestor: 2081dc33bc0657496c17f737f0f6d2f54479c246
Author: qulogic at pidgin.im
Date: 2008-06-29T20:01:14
Branch: im.pidgin.cpw.qulogic.msn
URL: http://d.pidgin.im/viewmtn/revision/info/95fe62719d362e8857a89e906a9008305e31dd5e

Modified files:
        libpurple/protocols/msn/notification.c

ChangeLog: 

When receiving an MSN OUT, don't try to dereference cmd->params when 
cmd->param_count is zero.

References #4332.

-------------- next part --------------
============================================================
--- libpurple/protocols/msn/notification.c	9ced204d9c55731f2747c5314d7399b311333b30
+++ libpurple/protocols/msn/notification.c	130be3aa14e0711d8577ef99a64ec65eebf82df7
@@ -328,7 +328,9 @@ out_cmd(MsnCmdProc *cmdproc, MsnCommand 
 static void
 out_cmd(MsnCmdProc *cmdproc, MsnCommand *cmd)
 {
-	if (!g_ascii_strcasecmp(cmd->params[0], "OTH"))
+	if (cmd->param_count == 0)
+		msn_session_set_error(cmdproc->session, -1, NULL);
+	else if (!g_ascii_strcasecmp(cmd->params[0], "OTH"))
 		msn_session_set_error(cmdproc->session, MSN_ERROR_SIGN_OTHER,
 							  NULL);
 	else if (!g_ascii_strcasecmp(cmd->params[0], "SSD"))


More information about the Commits mailing list