Mercurial > pidgin.yaz
changeset 8111:869d5a5495b8
[gaim-migrate @ 8812]
fix a segfault someone got (Robot101, this is a debian bug, but I'm too
lazy to look up the number)
committer: Tailor Script <tailor@pidgin.im>
author | Nathan Walp <nwalp@pidgin.im> |
---|---|
date | Thu, 15 Jan 2004 06:59:41 +0000 |
parents | 380d2bbdef1a |
children | 67387ec77301 |
files | src/log.c |
diffstat | 1 files changed, 11 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/src/log.c Thu Jan 15 06:58:58 2004 +0000 +++ b/src/log.c Thu Jan 15 06:59:41 2004 +0000 @@ -264,12 +264,20 @@ GDir *dir; GList *list = NULL; const char *filename; - char *me = g_strdup(gaim_normalize(account, gaim_account_get_username(account))); + char *me; + + const char *prpl; + char *path; + + if(!account) + return NULL; + + me = g_strdup(gaim_normalize(account, gaim_account_get_username(account))); /* does this seem like a bad way to get this component of the path to anyone else? --Nathan */ - const char *prpl = GAIM_PLUGIN_PROTOCOL_INFO + prpl = GAIM_PLUGIN_PROTOCOL_INFO (gaim_find_prpl(gaim_account_get_protocol_id(account)))->list_icon(account, NULL); - char *path = g_build_filename(gaim_user_dir(), "logs", prpl, me, gaim_normalize(account, screenname), NULL); + path = g_build_filename(gaim_user_dir(), "logs", prpl, me, gaim_normalize(account, screenname), NULL); g_free(me);