]> jfr.im git - solanum.git/blobdiff - src/whowas.c
Remove duplicate default-value code.
[solanum.git] / src / whowas.c
index aafe91b48bfe615ad3933c0379c62b3b400a0cb3..716bdccd48a4cd94f57c9a51244fe0468afa4ca5 100644 (file)
@@ -83,10 +83,9 @@ void add_history(struct Client *client_p, int online)
        strcpy(who->hostname, client_p->host);
        strcpy(who->realname, client_p->info);
        strcpy(who->suser, client_p->user->suser);
-       if (!EmptyString(client_p->sockhost) && strcmp(client_p->sockhost, "0") && show_ip(NULL, client_p))
-               strcpy(who->sockhost, client_p->sockhost);
-       else
-               who->sockhost[0] = '\0';
+       strcpy(who->sockhost, client_p->sockhost);
+       who->flags = (IsIPSpoof(client_p) ? WHOWAS_IP_SPOOFING : 0) |
+               (IsDynSpoof(client_p) ? WHOWAS_DYNSPOOF : 0);
 
        who->servername = scache_get_name(client_p->servptr->serv->nameinfo);