Changeset fa29d093 for protocols/yahoo
- Timestamp:
- 2007-03-28T05:53:11Z (18 years ago)
- Branches:
- master
- Children:
- 0da65d5
- Parents:
- 723e611
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
protocols/yahoo/yahoo.c
r723e611 rfa29d093 140 140 141 141 while( gc->conversations ) 142 serv_got_chat_left( gc , gc->conversations->id);142 serv_got_chat_left( gc->conversations ); 143 143 144 144 for( l = yd->buddygroups; l; l = l->next ) … … 332 332 } 333 333 334 static int byahoo_chat_send( struct gaim_connection *gc, int id, char *message ) 335 { 336 struct byahoo_data *yd = (struct byahoo_data *) gc->proto_data; 337 struct conversation *c; 338 339 for( c = gc->conversations; c && c->id != id; c = c->next ); 340 334 static int byahoo_chat_send( struct conversation *c, char *message ) 335 { 336 struct byahoo_data *yd = (struct byahoo_data *) c->gc->proto_data; 337 341 338 yahoo_conference_message( yd->y2_id, NULL, c->data, c->title, message, 1 ); 342 339 … … 344 341 } 345 342 346 static void byahoo_chat_invite( struct gaim_connection *gc, int id, char *msg, char *who ) 347 { 348 struct byahoo_data *yd = (struct byahoo_data *) gc->proto_data; 349 struct conversation *c; 350 351 for( c = gc->conversations; c && c->id != id; c = c->next ); 343 static void byahoo_chat_invite( struct conversation *c, char *msg, char *who ) 344 { 345 struct byahoo_data *yd = (struct byahoo_data *) c->gc->proto_data; 352 346 353 347 yahoo_conference_invite( yd->y2_id, NULL, c->data, c->title, msg ); 354 348 } 355 349 356 static void byahoo_chat_leave( struct gaim_connection *gc, int id ) 357 { 358 struct byahoo_data *yd = (struct byahoo_data *) gc->proto_data; 359 struct conversation *c; 360 361 for( c = gc->conversations; c && c->id != id; c = c->next ); 350 static void byahoo_chat_leave( struct conversation *c ) 351 { 352 struct byahoo_data *yd = (struct byahoo_data *) c->gc->proto_data; 362 353 363 354 yahoo_conference_logoff( yd->y2_id, NULL, c->data, c->title ); 364 serv_got_chat_left( gc, c->id);365 } 366 367 static intbyahoo_chat_open( struct gaim_connection *gc, char *who )355 serv_got_chat_left( c ); 356 } 357 358 static struct conversation *byahoo_chat_open( struct gaim_connection *gc, char *who ) 368 359 { 369 360 struct byahoo_data *yd = (struct byahoo_data *) gc->proto_data; … … 375 366 g_snprintf( roomname, strlen( gc->username ) + 16, "%s-Bee-%d", gc->username, byahoo_chat_id ); 376 367 377 c = serv_got_joined_chat( gc, ++byahoo_chat_id,roomname );368 c = serv_got_joined_chat( gc, roomname ); 378 369 add_chat_buddy( c, gc->username ); 379 370 … … 387 378 g_free( roomname ); 388 379 389 return ( 1 );380 return c; 390 381 } 391 382 … … 805 796 { 806 797 yahoo_conference_decline( inv->yid, NULL, inv->members, inv->name, "User rejected groupchat" ); 807 serv_got_chat_left( inv-> gc, inv->c->id);798 serv_got_chat_left( inv->c ); 808 799 g_free( inv->name ); 809 800 g_free( inv ); … … 820 811 memset( inv, 0, sizeof( struct byahoo_conf_invitation ) ); 821 812 inv->name = g_strdup( room ); 822 inv->c = serv_got_joined_chat( gc, ++byahoo_chat_id,room );813 inv->c = serv_got_joined_chat( gc, room ); 823 814 inv->c->data = members; 824 815 inv->yid = id; … … 872 863 for( c = gc->conversations; c && strcmp( c->title, room ) != 0; c = c->next ); 873 864 874 serv_got_chat_in( gc, c ? c->id : 0, who, 0, m, 0 ); 865 if( c ) 866 serv_got_chat_in( c, who, 0, m, 0 ); 875 867 g_free( m ); 876 868 }
Note: See TracChangeset
for help on using the changeset viewer.