Mercurial > pidgin.yaz
changeset 31908:d7be95afe03a
Tweak kartikmohta's patch a bit to use accessors instead of directly accessing
struct members, add the @since tag to the doxygen comment in the API addition,
and add the API addition to !ChangeLog.API. Refs #1131.
author | John Bailey <rekkanoryo@rekkanoryo.org> |
---|---|
date | Fri, 08 Apr 2011 01:21:15 +0000 |
parents | 4076f53cdd84 |
children | 60c0790a1f97 |
files | ChangeLog.API libpurple/pounce.c libpurple/pounce.h |
diffstat | 3 files changed, 9 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog.API Fri Apr 08 01:12:37 2011 +0000 +++ b/ChangeLog.API Fri Apr 08 01:21:15 2011 +0000 @@ -13,6 +13,7 @@ * purple_media_get_active_remote_candidates * purple_media_manager_get_video_caps (Jakub Adam) (#13095) * purple_media_manager_set_video_caps (Jakub Adam) (#13095) + * purple_pounce_destroy_all_by_buddy (Kartik Mohta) (#1131) * Added add_buddy_with_invite to PurplePluginProtocolInfo * Added add_buddies_with_invite to PurplePluginProtocolInfo * Added PurpleSrvTxtQueryUiOps which allow UIs to specify their
--- a/libpurple/pounce.c Fri Apr 08 01:12:37 2011 +0000 +++ b/libpurple/pounce.c Fri Apr 08 01:21:15 2011 +0000 @@ -697,13 +697,16 @@ void purple_pounce_destroy_all_by_buddy(PurpleBuddy *buddy) { - const char *pouncee; - PurpleAccount *pouncer; + const char *pouncee, *bname; + PurpleAccount *pouncer, *bacct; PurplePounce *pounce; GList *l, *l_next; g_return_if_fail(buddy != NULL); + bacct = purple_buddy_get_account(buddy); + bname = purple_buddy_get_name(buddy); + for (l = purple_pounces_get_all(); l != NULL; l = l_next) { pounce = (PurplePounce *)l->data; l_next = l->next; @@ -711,7 +714,7 @@ pouncer = purple_pounce_get_pouncer(pounce); pouncee = purple_pounce_get_pouncee(pounce); - if ( (pouncer == buddy->account) && (strcmp(pouncee, buddy->name) == 0) ) + if ( (pouncer == bacct) && (strcmp(pouncee, bname) == 0) ) purple_pounce_destroy(pounce); } }
--- a/libpurple/pounce.h Fri Apr 08 01:12:37 2011 +0000 +++ b/libpurple/pounce.h Fri Apr 08 01:21:15 2011 +0000 @@ -126,6 +126,8 @@ * Destroys all buddy pounces for a buddy * * @param buddy The buddy whose pounces are to be removed + * + * @since 2.8.0 */ void purple_pounce_destroy_all_by_buddy(PurpleBuddy *buddy);