Mercurial > pidgin.yaz
changeset 12441:d7dc4b33fd69
[gaim-migrate @ 14748]
Fix an abuse of g_return_val_if_fail, gaim_status_get_attr_value is called
on statuses that may not have the attribute set.
committer: Tailor Script <tailor@pidgin.im>
author | Stu Tomlinson <stu@nosnilmot.com> |
---|---|
date | Fri, 09 Dec 2005 12:46:24 +0000 |
parents | bfd3aca4647a |
children | 8edb08af68c7 |
files | src/status.c |
diffstat | 1 files changed, 3 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/status.c Fri Dec 09 07:26:29 2005 +0000 +++ b/src/status.c Fri Dec 09 12:46:24 2005 +0000 @@ -972,7 +972,9 @@ /* Make sure this attribute exists. */ attr = gaim_status_type_get_attr(status_type, id); - g_return_val_if_fail(attr != NULL, NULL); + + if (attr == NULL) + return NULL; return (GaimValue *)g_hash_table_lookup(status->attr_values, id); }