diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/xmpp/roster_list.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/xmpp/roster_list.c b/src/xmpp/roster_list.c index 7954e3de..920691d6 100644 --- a/src/xmpp/roster_list.c +++ b/src/xmpp/roster_list.c @@ -688,6 +688,15 @@ roster_compare_presence(PContact a, PContact b) } } +static void +_pendingPresence_free(ProfPendingPresence *presence) +{ + if (!presence) + return; + free(presence->barejid); + free(presence); +} + void roster_process_pending_presence(void) { @@ -704,7 +713,7 @@ roster_process_pending_presence(void) } } - g_slist_free(roster_pending_presence); + g_slist_free_full(roster_pending_presence, (GDestroyNotify)_pendingPresence_free); roster_pending_presence = NULL; } |