Changeset 69b896b
- Timestamp:
- 2010-07-05T12:01:28Z (14 years ago)
- Branches:
- master
- Children:
- 9a9b520
- Parents:
- 006a84f
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
bitlbee.c
r006a84f r69b896b 370 370 /* Try to save data for all active connections (if desired). */ 371 371 while( irc_connection_list != NULL ) 372 irc_free( irc_connection_list->data ); 372 irc_abort( irc_connection_list->data, FALSE, 373 "BitlBee server shutting down" ); 373 374 374 375 /* We'll only reach this point when not running in inetd mode: */ -
doc/user-guide/commands.xml
r006a84f r69b896b 1093 1093 </bitlbee-setting> 1094 1094 1095 <bitlbee-setting name="translate_to_nicks" type="boolean" scope="channel"> 1096 <default>true</default> 1097 1098 <description> 1099 <para> 1100 IRC's nickname namespace is quite limited compared to most IM protocols. Not any non-ASCII characters are allowed, in fact nicknames have to be mostly alpha-numeric. Also, BitlBee has to add underscores sometimes to avoid nickname collisions. 1101 </para> 1102 1103 <para> 1104 While normally the BitlBee user is the only one seeing these names, they may be exposed to other chatroom participants for example when addressing someone in the channel (with or without tab completion). By default BitlBee will translate these stripped nicknames back to the original nick. If you don't want this, disable this setting. 1105 </para> 1106 </description> 1107 </bitlbee-setting> 1108 1095 1109 <bitlbee-setting name="type" type="string" scope="channel"> 1096 1110 <default>control</default> -
irc_im.c
r006a84f r69b896b 603 603 { 604 604 struct groupchat *c = ic->data; 605 char *trans = NULL, *s; 605 606 606 607 if( c == NULL ) 607 608 return FALSE; 608 else if( set_getbool( &ic->irc->b->set, "paste_buffer" ) ) 609 610 if( set_getbool( &ic->set, "translate_to_nicks" ) ) 611 { 612 char nick[MAX_NICK_LENGTH+1]; 613 irc_user_t *iu; 614 615 strncpy( nick, msg, MAX_NICK_LENGTH ); 616 nick[MAX_NICK_LENGTH] = '\0'; 617 if( ( s = strchr( nick, ':' ) ) || ( s = strchr( nick, ',' ) ) ) 618 { 619 *s = '\0'; 620 if( ( iu = irc_user_by_name( ic->irc, nick ) ) && 621 iu->bu->nick && irc_channel_has_user( ic, iu ) ) 622 { 623 trans = g_strconcat( iu->bu->nick, msg + ( s - nick ), NULL ); 624 msg = trans; 625 } 626 } 627 } 628 629 if( set_getbool( &ic->irc->b->set, "paste_buffer" ) ) 609 630 { 610 631 int delay; … … 623 644 ic->pastebuf_timer = b_timeout_add( delay, bee_irc_channel_chat_privmsg_cb, ic ); 624 645 646 g_free( trans ); 625 647 return TRUE; 626 648 } … … 628 650 bee_chat_msg( ic->irc->b, c, msg, 0 ); 629 651 652 g_free( trans ); 630 653 return TRUE; 631 654 } … … 747 770 set_add( &ic->set, "nick", NULL, NULL, ic ); 748 771 set_add( &ic->set, "room", NULL, NULL, ic ); 772 set_add( &ic->set, "translate_to_nicks", "true", set_eval_bool, ic ); 749 773 750 774 /* chat_type == groupchat */ … … 790 814 set_del( &ic->set, "nick" ); 791 815 set_del( &ic->set, "room" ); 816 set_del( &ic->set, "translate_to_nicks" ); 792 817 793 818 ic->flags &= ~IRC_CHANNEL_TEMP; -
protocols/bee.h
r006a84f r69b896b 62 62 char *handle; 63 63 char *fullname; 64 char *nick; 64 65 struct bee_group *group; 65 66 -
protocols/bee_user.c
r006a84f r69b896b 60 60 g_free( bu->handle ); 61 61 g_free( bu->fullname ); 62 g_free( bu->nick ); 62 63 g_free( bu->status ); 63 64 g_free( bu->status_msg ); -
protocols/nogaim.c
r006a84f r69b896b 427 427 428 428 if( !bu || !nick ) return; 429 430 g_free( bu->nick ); 431 bu->nick = g_strdup( nick ); 429 432 430 433 if( bee->ui->user_nick_hint )
Note: See TracChangeset
for help on using the changeset viewer.