Changeset 471573f
- Timestamp:
- 2006-06-26T15:06:08Z (18 years ago)
- Branches:
- master
- Children:
- 90bbb0e
- Parents:
- c9f0c79 (diff), 2f13222 (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. - Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
irc.c
rc9f0c79 r471573f 657 657 c = conv_findchannel( channel ); 658 658 659 /* RFC 's say there is no error reply allowed on NAMES, so when the659 /* RFCs say there is no error reply allowed on NAMES, so when the 660 660 channel is invalid, just give an empty reply. */ 661 661 … … 671 671 s = ""; 672 672 673 irc_reply( irc, 353, " @%s :%s%s", channel, s, u->nick );673 irc_reply( irc, 353, "= %s :%s%s", channel, s, u->nick ); 674 674 } 675 675 else if( !u->gc ) … … 682 682 s = ""; 683 683 684 irc_reply( irc, 353, " @%s :%s%s", channel, s, u->nick );684 irc_reply( irc, 353, "= %s :%s%s", channel, s, u->nick ); 685 685 } 686 686 } … … 697 697 for( l = c->in_room; l; l = l->next ) 698 698 if( ( u = user_findhandle( c->gc, l->data ) ) ) 699 irc_reply( irc, 353, " @%s :%s%s", channel, "", u->nick );699 irc_reply( irc, 353, "= %s :%s%s", channel, "", u->nick ); 700 700 } 701 701 … … 735 735 irc_reply( irc, 5, "PREFIX=(ov)@+ CHANTYPES=#& CHANMODES=,,,%s NICKLEN=%d NETWORK=BitlBee CASEMAPPING=rfc1459 MAXTARGETS=1 WATCH=128 :are supported by this server", CMODES, MAX_NICK_LENGTH - 1 ); 736 736 irc_motd( irc ); 737 irc->umode[0] = '\0'; 737 738 irc_umode_set( irc, "+" UMODE, 1 ); 738 739 … … 842 843 char m[256], st = 1, *t; 843 844 int i; 845 char changes[512], *p, st2 = 2; 846 char badflag = 0; 844 847 845 848 memset( m, 0, sizeof( m ) ); … … 847 850 for( t = irc->umode; *t; t ++ ) 848 851 m[(int)*t] = 1; 849 852 853 p = changes; 850 854 for( t = s; *t; t ++ ) 851 855 { … … 853 857 st = *t == '+'; 854 858 else if( st == 0 || ( strchr( UMODES, *t ) || ( allow_priv && strchr( UMODES_PRIV, *t ) ) ) ) 859 { 860 if( m[(int)*t] != st) 861 { 862 if( st != st2 ) 863 st2 = st, *p++ = st ? '+' : '-'; 864 *p++ = *t; 865 } 855 866 m[(int)*t] = st; 856 } 867 } 868 else 869 badflag = 1; 870 } 871 *p = '\0'; 857 872 858 873 memset( irc->umode, 0, sizeof( irc->umode ) ); … … 862 877 irc->umode[strlen(irc->umode)] = i; 863 878 864 irc_reply( irc, 221, "+%s", irc->umode ); 879 if( badflag ) 880 irc_reply( irc, 501, ":Unknown MODE flag" ); 881 /* Deliberately no !user@host on the prefix here */ 882 if( *changes ) 883 irc_write( irc, ":%s MODE %s %s", irc->nick, irc->nick, changes ); 865 884 } 866 885 -
irc_commands.c
rc9f0c79 r471573f 119 119 if( cmd[2] ) 120 120 irc_umode_set( irc, cmd[2], 0 ); 121 else 122 irc_reply( irc, 221, "+%s", irc->umode ); 121 123 } 122 124 else … … 637 639 } 638 640 639 break; 640 } 641 } 641 return; 642 } 643 644 if( irc->status >= USTATUS_LOGGED_IN ) 645 irc_reply( irc, 421, "%s :Unknown command", cmd[0] ); 646 }
Note: See TracChangeset
for help on using the changeset viewer.