Changeset 75554d0 for protocols/msn/msn.c
- Timestamp:
- 2010-03-17T13:56:52Z (15 years ago)
- Branches:
- master
- Children:
- b788246
- Parents:
- e5e795d (diff), f9928cb (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
protocols/msn/msn.c
re5e795d r75554d0 26 26 #include "nogaim.h" 27 27 #include "msn.h" 28 29 int msn_chat_id; 30 GSList *msn_connections; 31 GSList *msn_switchboards; 28 32 29 33 static char *msn_set_display_name( set_t *set, char *value ); … … 139 143 140 144 if( l == NULL ) 141 for( i = 0; msn_away_state_list[i].number > -1; i ++ ) 142 l = g_list_append( l, (void*) msn_away_state_list[i].name ); 145 for( i = 0; *msn_away_state_list[i].code; i ++ ) 146 if( *msn_away_state_list[i].name ) 147 l = g_list_append( l, (void*) msn_away_state_list[i].name ); 143 148 144 149 return l; … … 149 154 char buf[1024]; 150 155 struct msn_data *md = ic->proto_data; 151 const struct msn_away_state *st;152 153 if( strcmp( state, GAIM_AWAY_CUSTOM ) == 0 )154 st = msn_away_state_by_name( "Away" );156 157 if( state ) 158 md->away_state = msn_away_state_by_name( state ) ? : 159 msn_away_state_list + 1; 155 160 else 156 st = msn_away_state_by_name( state ); 157 158 if( !st ) st = msn_away_state_list; 159 md->away_state = st; 160 161 g_snprintf( buf, sizeof( buf ), "CHG %d %s\r\n", ++md->trId, st->code ); 161 md->away_state = msn_away_state_list; 162 163 g_snprintf( buf, sizeof( buf ), "CHG %d %s\r\n", ++md->trId, md->away_state->code ); 162 164 msn_write( ic, buf, strlen( buf ) ); 163 165 }
Note: See TracChangeset
for help on using the changeset viewer.