Mercurial > pidgin.yaz
changeset 22877:76fa93017695
Make some functions static, plug a leak.
author | Sadrul Habib Chowdhury <imadil@gmail.com> |
---|---|
date | Tue, 19 Feb 2008 19:57:09 +0000 |
parents | bb1dc0095856 |
children | db31bbdf355b |
files | libpurple/smiley.c |
diffstat | 1 files changed, 9 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/libpurple/smiley.c Tue Feb 19 19:51:03 2008 +0000 +++ b/libpurple/smiley.c Tue Feb 19 19:57:09 2008 +0000 @@ -99,10 +99,10 @@ static PurpleSmiley *purple_smiley_create(const char *shortcut); -PurpleSmiley *purple_smiley_load_file(const char *shortcut, const char *checksum, +static PurpleSmiley *purple_smiley_load_file(const char *shortcut, const char *checksum, const char *filename); -void +static void purple_smiley_set_data_impl(PurpleSmiley *smiley, guchar *smiley_data, size_t smiley_data_len, const char *filename); @@ -282,7 +282,7 @@ return path; } -PurpleSmiley * +static PurpleSmiley * purple_smiley_load_file(const char *shortcut, const char *checksum, const char *filename) { PurpleSmiley *smiley = NULL; @@ -299,8 +299,10 @@ return NULL; smiley = purple_smiley_create(shortcut); - if (!smiley) + if (!smiley) { + g_free(fullpath); return NULL; + } smiley->checksum = g_strdup(checksum); @@ -310,6 +312,8 @@ else purple_smiley_delete(smiley); + g_free(fullpath); + return smiley; } @@ -420,7 +424,7 @@ return stored_img; } -void +static void purple_smiley_set_data_impl(PurpleSmiley *smiley, guchar *smiley_data, size_t smiley_data_len, const char *filename) {