1
0
mirror of https://github.com/anope/anope.git synced 2026-07-08 18:03:13 +02:00

BUILD : 1.7.5 (337) BUGS : N/A NOTES : Moved new channel registeration checks

git-svn-id: svn://svn.anope.org/anope/trunk@337 31f1291d-b8d6-0310-a050-a5561fc1590b


git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@213 5417fbe8-f217-4b02-8779-1006273d7864
This commit is contained in:
rob rob@31f1291d-b8d6-0310-a050-a5561fc1590b
2004-08-26 17:18:51 +00:00
parent 6c61225920
commit 7e7f83a2df
2 changed files with 9 additions and 16 deletions
+4 -15
View File
@@ -2515,30 +2515,19 @@ static int do_register(User * u)
return MOD_CONT;
}
/* Confirm that the channel is in the RFC spec */
if (*chan != '#' || *chan == '&') {
/* RFC says channels start with & or # so if the first is not # complain */
notice_lang(s_ChanServ, u, CHAN_SYMBOL_REQUIRED);
return MOD_CONT;
}
/* Throw a message that the channel is non existant */
if (!(c = findchan(chan))) {
alog("%s: %s attempted to register a non-existant channel [%s] ",
s_ChanServ, u->nick, chan);
notice_lang(s_NickServ, u, CHAN_REGISTER_NONE_CHANNEL, chan);
return MOD_CONT;
}
if (!desc) {
syntax_error(s_ChanServ, u, "REGISTER", CHAN_REGISTER_SYNTAX);
} else if (*chan == '&') {
notice_lang(s_ChanServ, u, CHAN_REGISTER_NOT_LOCAL);
} else if (*chan != '#') {
notice_lang(s_ChanServ, u, CHAN_SYMBOL_REQUIRED);
} else if (!u->na || !(nc = u->na->nc)) {
notice_lang(s_ChanServ, u, CHAN_MUST_REGISTER_NICK, s_NickServ);
} else if (!nick_recognized(u)) {
notice_lang(s_ChanServ, u, CHAN_MUST_IDENTIFY_NICK, s_NickServ,
s_NickServ);
} else if (!(c = findchan(chan))) {
notice_lang(s_NickServ, u, CHAN_REGISTER_NONE_CHANNEL, chan);
} else if ((ci = cs_findchan(chan)) != NULL) {
if (ci->flags & CI_VERBOTEN) {
alog("%s: Attempt to register FORBIDden channel %s by %s!%s@%s", s_ChanServ, ci->name, u->nick, u->username, common_get_vhost(u));
+5 -1
View File
@@ -8,10 +8,14 @@
VERSION_MAJOR="1"
VERSION_MINOR="7"
VERSION_PATCH="5"
VERSION_BUILD="336"
VERSION_BUILD="337"
# $Log$
#
# BUILD : 1.7.5 (337)
# BUGS : N/A
# NOTES : Moved new channel registeration checks
#
# BUILD : 1.7.5 (336)
# BUGS : 159
# NOTES : German langfile fixed