diff options
author | dequis <dx@dxzone.com.ar> | 2015-12-09 04:58:59 -0300 |
---|---|---|
committer | dequis <dx@dxzone.com.ar> | 2015-12-09 04:58:59 -0300 |
commit | 977a9d5473af8a13364c896eeb9ed83d55ce12e8 (patch) | |
tree | 5538989d32e1d3a1995f3c85e3b4f7ea571f53b8 /protocols/nogaim.c | |
parent | dbca297b4c3843ee82fa0531f47543a5cbb6f9d3 (diff) |
Revert "imc_away_send_update: Fix leak of away_states linked list"
This reverts commit ed431c389887080dc4fa45e30d051ce733f4ce57.
I'm going to let this leak. Turns out only purple allocates an empty
list for every time this is called. Other protocols have statics, and
they always return the same thing, can't free those. Whatever. The
purple leak was insignificant, just more scratching of itches.
Diffstat (limited to 'protocols/nogaim.c')
-rw-r--r-- | protocols/nogaim.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/protocols/nogaim.c b/protocols/nogaim.c index 0339feea..a5eda2e0 100644 --- a/protocols/nogaim.c +++ b/protocols/nogaim.c @@ -610,7 +610,6 @@ static char *imc_away_state_find(GList *gcm, char *away, char **message); int imc_away_send_update(struct im_connection *ic) { char *away, *msg = NULL; - GList *m = NULL; if (ic->acc->prpl->away_states == NULL || ic->acc->prpl->set_away == NULL) { @@ -620,7 +619,7 @@ int imc_away_send_update(struct im_connection *ic) away = set_getstr(&ic->acc->set, "away") ? : set_getstr(&ic->bee->set, "away"); if (away && *away) { - m = ic->acc->prpl->away_states(ic); + GList *m = ic->acc->prpl->away_states(ic); msg = ic->acc->flags & ACC_FLAG_AWAY_MESSAGE ? away : NULL; away = imc_away_state_find(m, away, &msg) ? : (imc_away_state_find(m, "away", &msg) ? : m->data); @@ -632,10 +631,6 @@ int imc_away_send_update(struct im_connection *ic) ic->acc->prpl->set_away(ic, away, msg); - while (m) { - m = g_list_delete_link(m, m); - } - return 1; } |