1
0
mirror of https://github.com/unrealircd/unrealircd.git synced 2026-07-10 06:23:13 +02:00

Made CmodeAdd return MODERR_EXISTS if the mode already exists

This commit is contained in:
codemastr
2004-01-08 16:51:29 +00:00
parent 1da0b9a540
commit 973ac25a4a
2 changed files with 7 additions and 0 deletions
+1
View File
@@ -2699,3 +2699,4 @@ seen. gmtime warning still there
- Fixed a compile problem reported by ace (#0001474)
- Added an EXTBAN 005 token (see doc/technical/005.txt for info)
- Fixed a bug with the dynamic umode and cmode systems
- Made CmodeAdd return MODERR_EXISTS if the mode already exists
+6
View File
@@ -120,6 +120,12 @@ Cmode *CmodeAdd(Module *reserved, CmodeInfo req, Cmode_t *mode)
{
if (!Channelmode_Table[i].flag)
break;
else if (Channelmode_Table[i].flag == req.flag)
{
if (reserved)
reserved->errorcode = MODERR_EXISTS;
return NULL;
}
i++;
}
if (i == EXTCMODETABLESZ)