From: w00t Date: Sat, 31 May 2008 18:44:15 +0000 (+0000) Subject: Forward port r9825: Fix bug found by the atheme migration testing: +V should never... X-Git-Tag: v2.0.23~3077 X-Git-Url: https://git.netwichtig.de/gitweb/?a=commitdiff_plain;h=0620c97abdf473ad536027c3b60efee517013fa1;p=user%2Fhenk%2Fcode%2Finspircd.git Forward port r9825: Fix bug found by the atheme migration testing: +V should never affect INVITE from a remote issuer git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9826 e03df62e-2008-0410-955e-edbf42e46eb7 --- diff --git a/src/modules/m_noinvite.cpp b/src/modules/m_noinvite.cpp index 0d6c56d99..0126b11c0 100644 --- a/src/modules/m_noinvite.cpp +++ b/src/modules/m_noinvite.cpp @@ -38,12 +38,15 @@ class ModuleNoInvite : public Module virtual int OnUserPreInvite(User* user,User* dest,Channel* channel, time_t timeout) { - if (channel->IsModeSet('V')) + if (IS_LOCAL(user)) { - user->WriteNumeric(492, "%s %s :Can't invite %s to channel (+V set)",user->nick.c_str(), channel->name.c_str(), dest->nick.c_str()); - return 1; + if (channel->IsModeSet('V')) + { + user->WriteNumeric(492, "%s %s :Can't invite %s to channel (+V set)",user->nick.c_str(), channel->name.c_str(), dest->nick.c_str()); + return 1; + } + return 0; } - return 0; } virtual ~ModuleNoInvite()