ownww = 1;
}
+ wnp = &ww->nick;
+
+ if (sender != target && (IsService(wnp) || IsOper(wnp) || NickOnServiceServer(wnp))) {
+ controlreply(sender, "Target user '%s' is an oper or a service. Not setting G-Lines.", wnp->nick);
+ return CMD_ERROR;
+ }
+
rejoinline(cargv[coff + 2], cargc - coff - 2);
reason = cargv[coff + 2];
glinebufcounthits(&gbuf, &hits, NULL);
id = glinebufcommit(&gbuf, 1);
- wnp = &ww->nick;
controlwall(NO_OPER, NL_GLINES, "%s BLOCK'ed user '%s!%s@%s' for %s with reason '%s' (%d hits)", controlid(sender),
wnp->nick, wnp->ident, wnp->host->name->content,
longtoduration(duration, 0), reason, hits);