neozeed ircu2.9.32-linux-hacks.diff

This commit is contained in:
2023-12-26 16:42:36 -05:00
parent ab64084f63
commit 51650c0d78
40 changed files with 718 additions and 720 deletions

View File

@@ -170,7 +170,7 @@ char *parv[];
*/
if ((*server == '*') && IsServer(cptr) &&
(aconf = cptr->serv->nline) &&
!mycmp(server, my_name_for_link(me.name, aconf)))
!strcasecmp(server, my_name_for_link(me.name, aconf)))
{
server = cptr->name;
acptr = cptr;
@@ -291,7 +291,7 @@ char *fmt, *p1, *p2, *p3, *host;
static int a_kills_b_too(a, b)
register aClient *a, *b;
{
for (; b != a && b != &me; b = b->serv->up)
for (; b != a && b != &me; b = b->serv->up);
return (a == b ? 1 : 0);
}
@@ -314,11 +314,11 @@ char *parv[];
Reg2 int i;
Reg3 Link *lp;
char info[REALLEN+1], *inpath, *host, *s;
aClient *acptr, *bcptr, *LHcptr;
aConfItem *aconf, *bconf, *cconf, *lhconf;
aClient *acptr, *bcptr, *LHcptr = NULL;
aConfItem *aconf, *bconf = NULL, *cconf, *lhconf = NULL;
int hop, ret, active_lh_line = 0;
u_short prot;
time_t start_timestamp, timestamp=0, recv_time, ghost=0;
time_t start_timestamp=0, timestamp=0, recv_time, ghost=0;
recv_time = TStime();
info[0] = '\0';
@@ -349,7 +349,7 @@ char *parv[];
Debug((DEBUG_INFO, "Got SERVER %s with timestamp [%s] age %lu (%lu)",
host, parv[4], start_timestamp, me.serv->timestamp));
if (prot>4 &&
(timestamp<780000000 || hop==1 && start_timestamp<780000000))
(timestamp<780000000 || (hop==1 && start_timestamp<780000000)))
{
return exit_client_msg(cptr, sptr, &me,
"Bogus timestamps (%s %s)", parv[3], parv[4]);
@@ -979,13 +979,12 @@ Reg2 aConfItem *aconf, *bconf;
{
Reg3 aClient *acptr;
Reg4 Link *lp;
char *inpath, *host, *s;
char *inpath, *s;
int split, i;
split = (mycmp(cptr->name, cptr->sockhost) &&
split = (strcasecmp(cptr->name, cptr->sockhost) &&
strncasecmp(cptr->info, "JUPE", 4));
inpath = get_client_name(cptr,TRUE);
host = cptr->name;
if (IsUnknown(cptr))
{
@@ -1098,7 +1097,7 @@ Reg2 aConfItem *aconf, *bconf;
acptr->name) == 0)
continue;
split = (MyConnect(acptr) &&
mycmp(acptr->name, acptr->sockhost) &&
strcasecmp(acptr->name, acptr->sockhost) &&
strncasecmp(acptr->info, "JUPE", 4));
if (split && Protocol(cptr)<9)
{
@@ -1432,7 +1431,7 @@ int mask;
port = (int)tmp->port;
/*
* On K line the passwd contents can be
/* displayed on STATS reply. -Vesa
* displayed on STATS reply. -Vesa
*/
if (tmp->status == CONF_KILL)
sendto_one(sptr, rpl_str(p[1]), me.name,
@@ -1477,7 +1476,7 @@ char *parv[];
if (parc > 2)
{
name = parv[2];
if (!mycmp(name, me.name))
if (!strcasecmp(name, me.name))
doall = 2;
else if (matches(name, me.name) == 0)
doall = 1;
@@ -1507,7 +1506,7 @@ char *parv[];
continue;
if (!doall && wilds && matches(name, acptr->name))
continue;
if (!(doall || wilds) && mycmp(name, acptr->name))
if (!(doall || wilds) && strcasecmp(name, acptr->name))
continue;
sendto_one(sptr, Lformat, me.name,
RPL_STATSLINKINFO, parv[0],
@@ -1755,15 +1754,18 @@ char *parv[];
(void)collapse(parv[1]);
for (acptr = client; acptr; acptr = acptr->next)
{
if (parc>1)
if (parc>1) {
if (!IsServer(acptr) && acptr->user)
{
if (match(parv[1], acptr->user->server->name))
continue;
}
else
{
if (match(parv[1], acptr->name))
continue;
}
}
switch (acptr->status)
{
@@ -2074,7 +2076,7 @@ char *parv[];
** parv[1] = new time
** parv[2] = servername
*/
m_settime(cptr, sptr, parc, parv)
int m_settime(cptr, sptr, parc, parv)
aClient *cptr, *sptr;
int parc;
char *parv[];
@@ -2417,8 +2419,8 @@ char *parv[];
for (i = 0; i < MAXCONNECTIONS; i++)
link_s[i] = 0, link_u[i] = 0;
if (doall)
for (acptr = client; acptr; acptr = acptr->next)
if (doall) {
for (acptr = client; acptr; acptr = acptr->next) {
#ifdef SHOW_INVISIBLE_LUSERS
if (IsPerson(acptr))
link_u[acptr->from->fd]++;
@@ -2429,6 +2431,8 @@ char *parv[];
#endif
else if (IsServer(acptr))
link_s[acptr->from->fd]++;
}
}
/* report all direct connections */
@@ -2445,7 +2449,7 @@ char *parv[];
continue;
if (!doall && wilds && matches(tname, acptr->name))
continue;
if (!dow && mycmp(tname, acptr->name))
if (!dow && strcasecmp(tname, acptr->name))
continue;
name = get_client_name(acptr,FALSE);
class = get_client_class(acptr);
@@ -2473,8 +2477,8 @@ char *parv[];
/* Only opers see users if there is a wildcard
* but anyone can see all the opers.
*/
if (IsOper(sptr) &&
(MyClient(sptr) || !(dow && IsInvisible(acptr)))
if ((IsOper(sptr) &&
(MyClient(sptr) || !(dow && IsInvisible(acptr))))
|| !dow || IsAnOper(acptr))
{
if (IsAnOper(acptr))
@@ -2754,7 +2758,7 @@ char *parv[];
continue;
}
if (!mycmp(agline->name, user) && !mycmp(agline->host, host))
if (!strcasecmp(agline->name, user) && !strcasecmp(agline->host, host))
break;
a2gline = agline;
@@ -2934,8 +2938,8 @@ char *parv[];
continue;
}
if ((!match(agline->name, user) || !mycmp(agline->name, user)) &&
(!match(agline->host, host) || !mycmp(agline->host, host)))
if ((!match(agline->name, user) || !strcasecmp(agline->name, user)) &&
(!match(agline->host, host) || !strcasecmp(agline->host, host)))
break;
a2gline = agline;