306 |
|
++ServerStats.is_ref; |
307 |
|
sendto_one_notice(source_p, &me, ":*** Notice -- You need to install " |
308 |
|
"identd to use this server"); |
309 |
< |
exit_client(source_p, &me, "Install identd"); |
309 |
> |
exit_client(source_p, "Install identd"); |
310 |
|
return; |
311 |
|
} |
312 |
|
|
332 |
|
++ServerStats.is_ref; |
333 |
|
|
334 |
|
sendto_one_numeric(source_p, &me, ERR_PASSWDMISMATCH); |
335 |
< |
exit_client(source_p, &me, "Bad Password"); |
335 |
> |
exit_client(source_p, "Bad Password"); |
336 |
|
return; |
337 |
|
} |
338 |
|
} |
363 |
|
"Too many clients, rejecting %s[%s].", |
364 |
|
source_p->name, source_p->host); |
365 |
|
++ServerStats.is_ref; |
366 |
< |
exit_client(source_p, &me, "Sorry, server is full - try later"); |
366 |
> |
exit_client(source_p, "Sorry, server is full - try later"); |
367 |
|
return; |
368 |
|
} |
369 |
|
|
378 |
|
++ServerStats.is_ref; |
379 |
|
snprintf(tmpstr2, sizeof(tmpstr2), "Invalid username [%s]", |
380 |
|
source_p->username); |
381 |
< |
exit_client(source_p, &me, tmpstr2); |
381 |
> |
exit_client(source_p, tmpstr2); |
382 |
|
return; |
383 |
|
} |
384 |
|
|
476 |
|
"No server %s for user %s[%s@%s] from %s", |
477 |
|
server, source_p->name, source_p->username, |
478 |
|
source_p->host, source_p->from->name); |
479 |
< |
kill_client(source_p->from, source_p, "%s (Server doesn't exist)", me.name); |
479 |
> |
sendto_one(source_p->from, |
480 |
> |
":%s KILL %s :%s (Ghosted, server %s doesn't exist)", |
481 |
> |
ID(&me), ID(source_p), me.name, server); |
482 |
|
|
483 |
|
AddFlag(source_p, FLAGS_KILLED); |
484 |
< |
exit_client(source_p, &me, "Ghosted Client"); |
484 |
> |
exit_client(source_p, "Ghosted Client"); |
485 |
|
return; |
486 |
|
} |
487 |
|
|
492 |
|
source_p->from->name, source_p->name, source_p->username, |
493 |
|
source_p->host, source_p->servptr->name, |
494 |
|
target_p->name, target_p->from->name); |
495 |
< |
kill_client(source_p->from, source_p, |
496 |
< |
"%s (NICK from wrong direction (%s != %s))", |
497 |
< |
me.name, source_p->servptr->name, target_p->from->name); |
495 |
> |
sendto_one(source_p->from, |
496 |
> |
":%s KILL %s :%s (NICK from wrong direction (%s != %s))", |
497 |
> |
ID(&me), ID(source_p), me.name, source_p->servptr->name, |
498 |
> |
target_p->from->name); |
499 |
> |
|
500 |
|
AddFlag(source_p, FLAGS_KILLED); |
501 |
< |
exit_client(source_p, &me, "USER server wrong direction"); |
501 |
> |
exit_client(source_p, "USER server wrong direction"); |
502 |
|
return; |
503 |
|
} |
504 |
|
|
748 |
|
/* set_user_mode() |
749 |
|
* |
750 |
|
* added 15/10/91 By Darren Reed. |
751 |
< |
* parv[0] - sender |
751 |
> |
* parv[0] - command |
752 |
|
* parv[1] - username to change mode for |
753 |
|
* parv[2] - modes to change |
754 |
|
*/ |
755 |
|
void |
756 |
< |
set_user_mode(struct Client *client_p, struct Client *source_p, |
753 |
< |
const int parc, char *parv[]) |
756 |
> |
set_user_mode(struct Client *source_p, const int parc, char *parv[]) |
757 |
|
{ |
758 |
|
unsigned int flag, setflags; |
759 |
|
char **p, *m, buf[IRCD_BUFSIZE]; |
762 |
|
|
763 |
|
assert(!(parc < 2)); |
764 |
|
|
765 |
< |
if ((target_p = find_person(client_p, parv[1])) == NULL) |
765 |
> |
if ((target_p = find_person(source_p, parv[1])) == NULL) |
766 |
|
{ |
767 |
|
if (MyConnect(source_p)) |
768 |
|
sendto_one_numeric(source_p, &me, ERR_NOSUCHCHANNEL, parv[1]); |
808 |
|
case 'o': |
809 |
|
if (what == MODE_ADD) |
810 |
|
{ |
811 |
< |
if (IsServer(client_p) && !HasUMode(source_p, UMODE_OPER)) |
811 |
> |
if (!MyConnect(source_p) && !HasUMode(source_p, UMODE_OPER)) |
812 |
|
{ |
813 |
|
++Count.oper; |
814 |
|
SetOper(source_p); |
884 |
|
* compare new flags with old flags and send string which |
885 |
|
* will cause servers to update correctly. |
886 |
|
*/ |
887 |
< |
send_umode_out(client_p, source_p, setflags); |
887 |
> |
send_umode_out(source_p, source_p, setflags); |
888 |
|
} |
889 |
|
|
890 |
|
/* send_umode() |
968 |
|
send_umode(NULL, source_p, old, SEND_UMODES, buf); |
969 |
|
|
970 |
|
if (buf[0]) |
971 |
< |
{ |
972 |
< |
DLINK_FOREACH(ptr, serv_list.head) |
970 |
< |
{ |
971 |
< |
struct Client *target_p = ptr->data; |
972 |
< |
|
973 |
< |
if ((target_p != client_p) && (target_p != source_p)) |
974 |
< |
sendto_one(target_p, ":%s MODE %s :%s", |
975 |
< |
ID_or_name(source_p, target_p), |
976 |
< |
ID_or_name(source_p, target_p), buf); |
977 |
< |
} |
978 |
< |
} |
971 |
> |
sendto_server(source_p, NOCAPS, NOCAPS, ":%s MODE %s :%s", |
972 |
> |
ID(source_p), ID(source_p), buf); |
973 |
|
|
974 |
|
if (client_p && MyClient(client_p)) |
975 |
|
send_umode(client_p, source_p, old, 0xffffffff, buf); |
1130 |
|
source_p->sockhost); |
1131 |
|
|
1132 |
|
++ServerStats.is_ref; |
1133 |
< |
exit_client(source_p, &me, "Bad user info"); |
1133 |
> |
exit_client(source_p, "Bad user info"); |
1134 |
|
return 1; |
1135 |
|
} |
1136 |
|
|