Mercurial > pidgin.yaz
diff pidgin/plugins/musicmessaging/musicmessaging.c @ 19992:e4dc98b8e140
Fix crash in musicmessaging plugin when something else has set the message to NULL (in this case, I'm guessing the Offline Messaging plugin). Fixes #3050.
author | Daniel Atallah <daniel.atallah@gmail.com> |
---|---|
date | Thu, 13 Sep 2007 02:38:20 +0000 |
parents | 44b4e8bd759b |
children | 3cc856ca2338 |
line wrap: on
line diff
--- a/pidgin/plugins/musicmessaging/musicmessaging.c Thu Sep 13 02:17:31 2007 +0000 +++ b/pidgin/plugins/musicmessaging/musicmessaging.c Thu Sep 13 02:38:20 2007 +0000 @@ -311,7 +311,9 @@ static gboolean intercept_sent(PurpleAccount *account, const char *who, char **message, void* pData) { - + if (message == NULL || *message == NULL || **message == '\0') + return FALSE; + if (0 == strncmp(*message, MUSICMESSAGING_PREFIX, strlen(MUSICMESSAGING_PREFIX))) { purple_debug_misc("purple-musicmessaging", "Sent MM Message: %s\n", *message);