- /* invalid username or host? */
- if(!clean_username(parv[5]) || !clean_host(parv[6]))
- {
- ServerStats->is_kill++;
- sendto_realops_snomask(SNO_DEBUG, L_ALL,
- "Bad user@host: %s@%s From: %s(via %s)",
- parv[5], parv[6], parv[7], client_p->name);
- sendto_one(client_p, ":%s KILL %s :%s (Bad user@host)", me.name, parv[1], me.name);
- return 0;
- }
-
- /* check the length of the clients gecos */
- if(strlen(parv[8]) > REALLEN)
- {
- char *s = LOCAL_COPY(parv[8]);
- /* why exactly do we care? --fl */
- sendto_realops_snomask(SNO_GENERAL, L_ALL,
- "Long realname from server %s for %s", parv[7], parv[1]);
-
- s[REALLEN] = '\0';
- parv[8] = s;
- }
-
- newts = atol(parv[3]);
-
- target_p = find_named_client(parv[1]);
-
- /* if the nick doesnt exist, allow it and process like normal */
- if(target_p == NULL)
- {
- register_client(client_p, NULL, parv[1], newts, parc, parv);
- }
- else if(IsUnknown(target_p))
- {
- exit_client(NULL, target_p, &me, "Overridden");
- register_client(client_p, NULL, parv[1], newts, parc, parv);
- }
- else if(target_p == source_p)
- {
- /* client changing case of nick */
- if(strcmp(target_p->name, parv[1]))
- register_client(client_p, NULL, parv[1], newts, parc, parv);
- }
- /* we've got a collision! */
- else
- perform_nick_collides(source_p, client_p, target_p, parc, parv,
- newts, parv[1], NULL);