* along with this program; if not, write to the Free Software
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*
- * $Id: m_gline.c,v 1.26 2004/12/11 05:13:46 klmitch Exp $
+ * $Id: m_gline.c,v 1.26.2.1 2006/06/09 02:13:51 entrope Exp $
*/
/*
if (!find_conf_byhost(cli_confs(cptr), cli_name(sptr), CONF_UWORLD))
return need_more_params(sptr, "GLINE");
- if (parc > 4)
- reason = parv[4];
flags |= GLINE_FORCE;
}
else if (parc > 5)
- {
lastmod = atoi(parv[4]);
- reason = parv[5];
- }
else
return need_more_params(sptr, "GLINE");
+ if (parc > 4)
+ reason = parv[parc - 1];
+
if (IsServer(sptr))
flags |= GLINE_FORCE;
if (!(target[0] == '*' && target[1] == '\0')) {
- if (!(acptr = FindNServer(target)))
+ if (!( (acptr = FindNServer(target)) ||
+ (acptr = SeekServer(target)) ) )
return 0; /* no such server */
if (!IsMe(acptr)) { /* manually propagate */
if (!lastmod)
sendcmdto_one(sptr, CMD_GLINE, acptr,
- (parc == 3) ? "%C %s" : "%C %s %s :%s", acptr, mask,
+ (parc == 3) ? "%s %s" : "%s %s %s :%s", target, mask,
parv[3], reason);
else
- sendcmdto_one(sptr, CMD_GLINE, acptr, "%C %s%s %s %s :%s", acptr,
+ sendcmdto_one(sptr, CMD_GLINE, acptr, "%s %s%s %s %s :%s", target,
flags & GLINE_OPERFORCE ? "!" : "", mask, parv[3],
parv[4], reason);
return 0;
}
- flags |= GLINE_LOCAL;
+ /* For asuka we don't want glines sent this way treated as local
+ * flags |= GLINE_LOCAL;
+ */
}
if (*mask == '-')
int
m_gline(struct Client *cptr, struct Client *sptr, int parc, char *parv[])
{
+ if (feature_bool(FEAT_HIS_USERGLINE))
+ return send_reply(sptr, ERR_DISABLED, "GLINE");
+
if (parc < 2)
return send_reply(sptr, ERR_NOSUCHGLINE, "");