ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/svn/ircd-hybrid-7.3/modules/m_whois.c
(Generate patch)

Comparing ircd-hybrid-7.2/modules/m_whois.c (file contents):
Revision 279 by adx, Mon Nov 14 19:39:09 2005 UTC vs.
Revision 280 by db, Wed Nov 23 23:09:48 2005 UTC

# Line 424 | Line 424 | whois_person(struct Client *source_p, st
424      sendto_one(source_p, form_str(RPL_ISCAPTURED),
425                 me.name, source_p->name, target_p->name);
426  
427 <  if (ConfigFileEntry.use_whois_actually && (target_p->sockhost[0] != '\0') &&
428 <      !(ConfigFileEntry.hide_spoof_ips && IsIPSpoof(target_p)) &&
429 <      !(target_p->sockhost[0] == '0' && target_p->sockhost[1] == '\0'))
427 >  if (ConfigFileEntry.use_whois_actually)
428    {
429 <    if (IsAdmin(source_p) || source_p == target_p)
430 <      sendto_one(source_p, form_str(RPL_WHOISACTUALLY),
431 <                 me.name, source_p->name, target_p->name, target_p->sockhost);
432 <    else
433 <      sendto_one(source_p, form_str(RPL_WHOISACTUALLY),
434 <                 me.name, source_p->name, target_p->name,
435 <                 IsIPSpoof(target_p) || IsOper(target_p) ?
436 <                 "255.255.255.255" : target_p->sockhost);
429 >    int show_ip = 0;
430 >
431 >    if ((target_p->sockhost[0] != '\0') && (target_p->sockhost[0] == '0' &&
432 >                                            target_p->sockhost[1] == '\0'))
433 >    {
434 >      if ((IsAdmin(source_p) || source_p == target_p))
435 >        show_ip = 1;
436 >      else if (IsIPSpoof(target_p))
437 >        show_ip = (IsOper(source_p) && !ConfigFileEntry.hide_spoof_ips);
438 >      else
439 >        show_ip = 1;
440 >
441 >        sendto_one(source_p, form_str(RPL_WHOISACTUALLY),
442 >                   me.name, source_p->name, target_p->name,
443 >                   show_ip ? target_p->sockhost : "255.255.255.255");
444 >    }
445    }
446  
447    if (MyConnect(target_p)) /* Can't do any of this if not local! db */

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines