1
0
mirror of https://github.com/anope/anope.git synced 2026-06-30 05:36:38 +02:00

Fix usermode parsing for InspIRCd 1.2

git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@1686 5417fbe8-f217-4b02-8779-1006273d7864
This commit is contained in:
rburchell
2008-11-15 00:21:47 +00:00
parent 83a7ad7480
commit 2d07704bb6
+10 -7
View File
@@ -715,18 +715,21 @@ int anope_event_ftopic(const char *source, int ac, const char **av)
int anope_event_mode(const char *source, int ac, const char **av)
{
if (*av[0] == '#' || *av[0] == '&') {
if (*av[0] == '#' || *av[0] == '&')
{
do_cmode(source, ac, av);
} else {
}
else
{
/* InspIRCd lets opers change another
users modes, we have to kludge this
as it slightly breaks RFC1459
*/
if (!strcasecmp(source, av[0])) {
do_umode(source, ac, av);
} else {
do_umode(av[0], ac, av);
}
User *u = find_byuid(source);
User *u2 = find_byuid(av[0]);
av[0] = u2->nick;
do_umode(u->nick, ac, av);
}
return MOD_CONT;
}