This patch changes userip and userhost replies to the real ip/hostname for
users with hidden hostnames, who request their own info ... useful to help
clients with dcc stuff.
--
+++ GMX - Mail, Messaging & more http://www.gmx.net +++
NEU: Mit GMX ins Internet. Rund um die Uhr f�r 1 ct/ Min. surfen!
Index: ChangeLog
===================================================================
RCS file: /cvsroot/undernet-ircu/ircu2.10/ChangeLog,v
retrieving revision 1.370
diff -u -r1.370 ChangeLog
--- ChangeLog 10 Jan 2003 09:20:25 -0000 1.370
+++ ChangeLog 10 Jan 2003 22:13:56 -0000
@@ -1,3 +1,8 @@
+2003-01-10 volta <[EMAIL PROTECTED]>
+ * ircd/m_userip.c, ircd/m_userhost.c: Small fix, that
+ allows users to see their own ip & hostname. (Should solve
+ all problems with dcc)
+
2003-01-10 Thomas Helvey <[EMAIL PROTECTED]>
* ircd/map.c, ircd/Makefile.in, include/map.h: Remove
HEAD_IN_SAND macros to get server to build, rebuild dependencies.
Index: ircd/m_userhost.c
===================================================================
RCS file: /cvsroot/undernet-ircu/ircu2.10/ircd/m_userhost.c,v
retrieving revision 1.11
diff -u -r1.11 m_userhost.c
--- ircd/m_userhost.c 8 Jan 2003 03:17:19 -0000 1.11
+++ ircd/m_userhost.c 10 Jan 2003 22:14:01 -0000
@@ -97,7 +97,7 @@
msgq_append(0, mb, "%s%s=%c%s@%s", cli_name(cptr),
HasPriv(cptr, PRIV_DISPLAY) ? "*" : "",
cli_user(cptr)->away ? '-' : '+', cli_user(cptr)->username,
- HasHiddenHost(cptr) && !IsAnOper(sptr) ?
+ HasHiddenHost(cptr) && !IsAnOper(sptr) && (sptr != cptr) ?
cli_user(cptr)->host : cli_user(cptr)->realhost);
}
Index: ircd/m_userip.c
===================================================================
RCS file: /cvsroot/undernet-ircu/ircu2.10/ircd/m_userip.c,v
retrieving revision 1.10
diff -u -r1.10 m_userip.c
--- ircd/m_userip.c 3 Apr 2002 15:23:48 -0000 1.10
+++ ircd/m_userip.c 10 Jan 2003 22:14:01 -0000
@@ -98,7 +98,7 @@
msgq_append(0, mb, "%s%s=%c%s@%s", cli_name(cptr),
HasPriv(cptr, PRIV_DISPLAY) ? "*" : "",
cli_user(cptr)->away ? '-' : '+', cli_user(cptr)->username,
- HasHiddenHost(cptr) && !IsAnOper(sptr) ?
+ HasHiddenHost(cptr) && !IsAnOper(sptr) && (sptr != cptr) ?
feature_str(FEAT_HIDDEN_IP) :
ircd_ntoa((const char*) &(cli_ip(cptr))));
}