- Timestamp:
- 2008-01-18T13:20:37Z (17 years ago)
- Branches:
- master
- Children:
- bea1305
- Parents:
- ac4adf9
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
protocols/nogaim.c
rac4adf9 r83ba3e5 692 692 } 693 693 694 struct groupchat *imcb_chat_new( struct im_connection *ic, char *handle ) 695 { 696 struct groupchat *c; 697 698 /* This one just creates the conversation structure, user won't see anything yet */ 699 700 if( ic->groupchats ) 701 { 702 for( c = ic->groupchats; c->next; c = c->next ); 703 c = c->next = g_new0( struct groupchat, 1 ); 704 } 705 else 706 ic->groupchats = c = g_new0( struct groupchat, 1 ); 707 708 c->ic = ic; 709 c->title = g_strdup( handle ); 710 c->channel = g_strdup_printf( "&chat_%03d", ic->irc->c_id++ ); 711 c->topic = g_strdup_printf( "BitlBee groupchat: \"%s\". Please keep in mind that root-commands won't work here. Have fun!", c->title ); 712 713 if( set_getbool( &ic->irc->set, "debug" ) ) 714 imcb_log( ic, "Creating new conversation: (id=%p,handle=%s)", c, handle ); 715 716 return c; 717 } 718 694 719 void imcb_chat_free( struct groupchat *c ) 695 720 { … … 728 753 g_free( c->channel ); 729 754 g_free( c->title ); 755 g_free( c->topic ); 730 756 g_free( c ); 731 757 } … … 781 807 if( c->joined && u ) 782 808 irc_write( ic->irc, ":%s!%s@%s TOPIC %s :%s", u->nick, u->user, u->host, c->channel, topic ); 783 }784 785 struct groupchat *imcb_chat_new( struct im_connection *ic, char *handle )786 {787 struct groupchat *c;788 789 /* This one just creates the conversation structure, user won't see anything yet */790 791 if( ic->groupchats )792 {793 for( c = ic->groupchats; c->next; c = c->next );794 c = c->next = g_new0( struct groupchat, 1 );795 }796 else797 ic->groupchats = c = g_new0( struct groupchat, 1 );798 799 c->ic = ic;800 c->title = g_strdup( handle );801 c->channel = g_strdup_printf( "&chat_%03d", ic->irc->c_id++ );802 c->topic = g_strdup_printf( "%s :BitlBee groupchat: \"%s\". Please keep in mind that root-commands won't work here. Have fun!", c->channel, c->title );803 804 if( set_getbool( &ic->irc->set, "debug" ) )805 imcb_log( ic, "Creating new conversation: (id=%p,handle=%s)", c, handle );806 807 return c;808 809 } 809 810
Note: See TracChangeset
for help on using the changeset viewer.