# HG changeset patch # User Christian Hammond # Date 1071296031 0 # Node ID 59f9508c9a31f32f856e8e3e82006572cb63b131 # Parent a6298fd7ee21c85c6b3fe3cceb89cb2f5b093068 [gaim-migrate @ 8499] Sean got a really odd piece of MSNSLP data that wasn't documented anywhere I looked, and it appeared to have no content-type.. or maybe something got corrupted, but it looked pretty valid to me. Anyhow, this will prevent the crash (at least at this stage), since we no longer assume a content type exists. committer: Tailor Script diff -r a6298fd7ee21 -r 59f9508c9a31 src/protocols/msn/msg.c --- a/src/protocols/msn/msg.c Sat Dec 13 02:49:45 2003 +0000 +++ b/src/protocols/msn/msg.c Sat Dec 13 06:13:51 2003 +0000 @@ -136,6 +136,7 @@ MsnMessage *msg; char *command_header; char *tmp_base, *msg_base, *tmp, *field1, *field2, *c; + const char *content_type; const char *c2; g_return_val_if_fail(str != NULL, NULL); @@ -244,7 +245,10 @@ tmp += 2; /* Now we *should* be at the body. */ - if (!strcmp(msn_message_get_content_type(msg), "application/x-msnmsgrp2p")) + content_type = msn_message_get_content_type(msg); + + if (content_type != NULL && + !strcmp(content_type, "application/x-msnmsgrp2p")) { char header[48]; char footer[4];