# HG changeset patch # User Evan Schoenberg # Date 1167160923 0 # Node ID 132db06150ca82f7252510d7436a9f2030d30ee2 # Parent 6388c384bfacfafd0fe8143f26a063c066672ec9 [gaim-migrate @ 18058] * Nathan and I decided that there's no reason for having the if (value != old_value) checks in the setters; it's a convention which makes sense in my 'native' Objective-C but is silly here. * Fixed a return in g_return_val_if_fail(): gaim_notify_user_info_entry_get_type() returns a GaimNotifyUserInfoEntryType, not a pointer. committer: Tailor Script diff -r 6388c384bfac -r 132db06150ca libgaim/notify.c --- a/libgaim/notify.c Tue Dec 26 03:39:37 2006 +0000 +++ b/libgaim/notify.c Tue Dec 26 19:22:03 2006 +0000 @@ -585,11 +585,8 @@ { g_return_if_fail(user_info_entry != NULL); - if (label != user_info_entry->label) - { - g_free(user_info_entry->label); - user_info_entry->label = g_strdup(label); - } + g_free(user_info_entry->label); + user_info_entry->label = g_strdup(label); } gchar * @@ -605,18 +602,15 @@ { g_return_if_fail(user_info_entry != NULL); - if (value != user_info_entry->value) - { - g_free(user_info_entry->value); - user_info_entry->value = g_strdup(value); - } + g_free(user_info_entry->value); + user_info_entry->value = g_strdup(value); } GaimNotifyUserInfoEntryType gaim_notify_user_info_entry_get_type(GaimNotifyUserInfoEntry *user_info_entry) { - g_return_val_if_fail(user_info_entry != NULL, NULL); - + g_return_val_if_fail(user_info_entry != NULL, GAIM_NOTIFY_USER_INFO_ENTRY_PAIR); + return user_info_entry->type; }