* ircd/Makefile.in (install-*): Remove commented-out code to touch
and chown MPATH and RPATH.
+ * ircd/gline.c (gline_find): Allow searching for host-based
+ G-lines by plain hostname (not *@host), thus preventing "GLINE
+ test ..." from inserting duplicate G-lines.
+
2005-01-26 Michael Poole <mdpoole@troilus.org>
* include/ircd_alloc.h (DoMallocZero): Parenthesize macro
return 0;
DupString(t_uh, userhost);
- canon_userhost(t_uh, &user, &host, 0);
-
- if (BadPtr(user))
- return 0;
+ canon_userhost(t_uh, &user, &host, "*");
for (gline = GlobalGlineList; gline; gline = sgline) {
sgline = gline->gl_next;
else if (flags & GLINE_EXACT) {
if (((gline->gl_host && host && ircd_strcmp(gline->gl_host, host) == 0)
|| (!gline->gl_host && !host)) &&
- ((!user && ircd_strcmp(gline->gl_user, "*") == 0) ||
- ircd_strcmp(gline->gl_user, user) == 0))
+ (ircd_strcmp(gline->gl_user, user) == 0))
break;
} else {
if (((gline->gl_host && host && match(gline->gl_host, host) == 0)
|| (!gline->gl_host && !host)) &&
- ((!user && ircd_strcmp(gline->gl_user, "*") == 0) ||
- match(gline->gl_user, user) == 0))
+ (match(gline->gl_user, user) == 0))
break;
}
}