aboutsummaryrefslogtreecommitdiffstats
path: root/protocols/msn/msn.c
diff options
context:
space:
mode:
authorWilmer van der Gaast <wilmer@gaast.net>2006-09-23 18:18:24 +0200
committerWilmer van der Gaast <wilmer@gaast.net>2006-09-23 18:18:24 +0200
commit5e202b09f2cd9faff5f316ae6804facb5342eace (patch)
treed2531aa515457d66b303cbcb94ea5d7243fcb041 /protocols/msn/msn.c
parentd8e04849607d4a5ca590752dce37954f12179580 (diff)
Implemented a list of away states, using this for a better set_away(), and
got rid of the double <presence> tag sent because of presence_announce().
Diffstat (limited to 'protocols/msn/msn.c')
-rw-r--r--protocols/msn/msn.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/protocols/msn/msn.c b/protocols/msn/msn.c
index 01b011c7..d36d861f 100644
--- a/protocols/msn/msn.c
+++ b/protocols/msn/msn.c
@@ -182,13 +182,14 @@ static int msn_send_im( struct gaim_connection *gc, char *who, char *message, in
static GList *msn_away_states( struct gaim_connection *gc )
{
- GList *l = NULL;
+ static GList *l = NULL;
int i;
- for( i = 0; msn_away_state_list[i].number > -1; i ++ )
- l = g_list_append( l, (void*) msn_away_state_list[i].name );
+ if( l == NULL )
+ for( i = 0; msn_away_state_list[i].number > -1; i ++ )
+ l = g_list_append( l, (void*) msn_away_state_list[i].name );
- return( l );
+ return l;
}
static char *msn_get_status_string( struct gaim_connection *gc, int number )