127 |
|
UMODE_WALLOP, /* w */ |
128 |
|
UMODE_HIDDENHOST, /* x */ |
129 |
|
UMODE_SPY, /* y */ |
130 |
< |
UMODE_OPERWALL, /* z 0x7A */ |
130 |
> |
0, /* z 0x7A */ |
131 |
|
0,0,0,0,0, /* 0x7B - 0x7F */ |
132 |
|
|
133 |
|
/* 0x80 */ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* 0x8F */ |
175 |
|
if (dlink_list_length(&unknown_list)) |
176 |
|
sendto_one_numeric(source_p, &me, RPL_LUSERUNKNOWN, dlink_list_length(&unknown_list)); |
177 |
|
|
178 |
< |
if (dlink_list_length(&global_channel_list)) |
179 |
< |
sendto_one_numeric(source_p, &me, RPL_LUSERCHANNELS, dlink_list_length(&global_channel_list)); |
178 |
> |
if (dlink_list_length(&channel_list)) |
179 |
> |
sendto_one_numeric(source_p, &me, RPL_LUSERCHANNELS, dlink_list_length(&channel_list)); |
180 |
|
|
181 |
|
if (!ConfigServerHide.hide_servers || HasUMode(source_p, UMODE_OPER)) |
182 |
|
{ |
286 |
|
char ubuf[IRCD_BUFSIZE] = ""; |
287 |
|
|
288 |
|
if (MyClient(source_p)) |
289 |
< |
send_umode(source_p, source_p, 0, SEND_UMODES, ubuf); |
289 |
> |
send_umode(source_p, source_p, 0, ubuf); |
290 |
|
else |
291 |
< |
send_umode(NULL, source_p, 0, SEND_UMODES, ubuf); |
291 |
> |
send_umode(NULL, source_p, 0, ubuf); |
292 |
|
|
293 |
|
watch_check_hash(source_p, RPL_LOGON); |
294 |
|
|
722 |
|
int |
723 |
|
valid_username(const char *username, const int local) |
724 |
|
{ |
725 |
< |
int dots = 0; |
725 |
> |
unsigned int dots = 0; |
726 |
|
const char *p = username; |
727 |
|
|
728 |
|
assert(p); |
742 |
|
{ |
743 |
|
while (*++p) |
744 |
|
{ |
745 |
< |
if ((*p == '.') && ConfigFileEntry.dots_in_ident) |
745 |
> |
if (*p == '.' && ConfigFileEntry.dots_in_ident) |
746 |
|
{ |
747 |
|
if (++dots > ConfigFileEntry.dots_in_ident) |
748 |
|
return 0; |
760 |
|
return 0; |
761 |
|
} |
762 |
|
|
763 |
< |
return p - username <= USERLEN;; |
763 |
> |
return p - username <= USERLEN; |
764 |
|
} |
765 |
|
|
766 |
|
/* clean_nick_name() |
803 |
|
*/ |
804 |
|
void |
805 |
|
send_umode(struct Client *client_p, struct Client *source_p, |
806 |
< |
unsigned int old, unsigned int sendmask, char *umode_buf) |
806 |
> |
unsigned int old, char *umode_buf) |
807 |
|
{ |
808 |
|
char *m = umode_buf; |
809 |
|
int what = 0; |
819 |
|
if (!flag) |
820 |
|
continue; |
821 |
|
|
822 |
– |
if (MyClient(source_p) && !(flag & sendmask)) |
823 |
– |
continue; |
824 |
– |
|
822 |
|
if ((flag & old) && !HasUMode(source_p, flag)) |
823 |
|
{ |
824 |
|
if (what == MODE_DEL) |
863 |
|
{ |
864 |
|
char buf[IRCD_BUFSIZE] = ""; |
865 |
|
|
866 |
< |
send_umode(NULL, source_p, old, SEND_UMODES, buf); |
866 |
> |
send_umode(NULL, source_p, old, buf); |
867 |
|
|
868 |
|
if (buf[0]) |
869 |
|
sendto_server(source_p, NOCAPS, NOCAPS, ":%s MODE %s :%s", |
870 |
|
source_p->id, source_p->id, buf); |
871 |
|
|
872 |
|
if (client_p && MyClient(client_p)) |
873 |
< |
send_umode(client_p, source_p, old, 0xffffffff, buf); |
873 |
> |
send_umode(client_p, source_p, old, buf); |
874 |
|
} |
875 |
|
|
876 |
|
void |
1047 |
|
* note this is a recursive function |
1048 |
|
*/ |
1049 |
|
static void |
1050 |
< |
add_one_to_uid(int i) |
1050 |
> |
add_one_to_uid(unsigned int i) |
1051 |
|
{ |
1052 |
|
if (i != IRC_MAXSID) /* Not reached server SID portion yet? */ |
1053 |
|
{ |
1056 |
|
else if (new_uid[i] == '9') |
1057 |
|
{ |
1058 |
|
new_uid[i] = 'A'; |
1059 |
< |
add_one_to_uid(i-1); |
1059 |
> |
add_one_to_uid(i - 1); |
1060 |
|
} |
1061 |
|
else |
1062 |
|
++new_uid[i]; |
1100 |
|
add_isupport("DEAF", "D", -1); |
1101 |
|
add_isupport("KICKLEN", NULL, KICKLEN); |
1102 |
|
add_isupport("MODES", NULL, MAXMODEPARAMS); |
1106 |
– |
#ifdef HALFOPS |
1103 |
|
add_isupport("PREFIX", "(ohv)@%+", -1); |
1104 |
|
add_isupport("STATUSMSG", "@%+", -1); |
1109 |
– |
#else |
1110 |
– |
add_isupport("PREFIX", "(ov)@+", -1); |
1111 |
– |
add_isupport("STATUSMSG", "@+", -1); |
1112 |
– |
#endif |
1105 |
|
add_isupport("EXCEPTS", "e", -1); |
1106 |
|
add_isupport("INVEX", "I", -1); |
1107 |
|
} |
1119 |
|
add_isupport(const char *name, const char *options, int n) |
1120 |
|
{ |
1121 |
|
dlink_node *ptr; |
1122 |
< |
struct Isupport *support; |
1122 |
> |
struct Isupport *support = NULL; |
1123 |
|
|
1124 |
|
DLINK_FOREACH(ptr, support_list.head) |
1125 |
|
{ |