Mercurial > pidgin
changeset 19628:4c5e7db85e29
For status messages, make sure NULL isn't passed to g_markup_escape_text().
author | Jeffrey Connelly <jaconnel@calpoly.edu> |
---|---|
date | Wed, 05 Sep 2007 04:18:59 +0000 |
parents | 5f8fb3aa0aeb |
children | 9968fff36e20 |
files | libpurple/protocols/myspace/myspace.c |
diffstat | 1 files changed, 8 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/libpurple/protocols/myspace/myspace.c Tue Sep 04 05:14:52 2007 +0000 +++ b/libpurple/protocols/myspace/myspace.c Wed Sep 05 04:18:59 2007 +0000 @@ -1856,9 +1856,14 @@ purple_debug_info("msim", "msim_status: found buddy %s\n", username); } - /* The status headline is plaintext, but libpurple treats it as HTML, - * so escape any HTML characters to their entity equivalents. */ - status_headline_escaped = g_markup_escape_text(status_headline, strlen(status_headline)); + if (status_headline) { + /* The status headline is plaintext, but libpurple treats it as HTML, + * so escape any HTML characters to their entity equivalents. */ + status_headline_escaped = g_markup_escape_text(status_headline, strlen(status_headline)); + } else { + status_headline_escaped = NULL; + } + g_free(status_headline); if (user->headline)