]> git.netwichtig.de Git - user/henk/code/inspircd.git/commitdiff
Merge pull request #145 from SaberUK/insp20-typo-fixes
authorRobin Burchell <viroteck@viroteck.net>
Sun, 27 May 2012 13:07:55 +0000 (06:07 -0700)
committerRobin Burchell <viroteck@viroteck.net>
Sun, 27 May 2012 13:07:55 +0000 (06:07 -0700)
[2.0] Typo fixes.

src/modules/m_mlock.cpp

index 17deb17bd9961806aa858140c5f79f789584ffe6..b5f34c93614fa644a17b1dd799ddfeeab77f70cc 100644 (file)
@@ -29,6 +29,7 @@ public:
        void init()
        {
                ServerInstance->Modules->Attach(I_OnPreMode, this);
+               ServerInstance->Extensions.Register(&this->mlock);
        }
 
        Version GetVersion()
@@ -55,7 +56,7 @@ public:
 
                for (const char *modes = parameters[1].c_str(); *modes; modes++)
                {
-                       if (mlock_str->find(*modes))
+                       if (mlock_str->find(*modes) != std::string::npos)
                        {
                                source->WriteNumeric(742, "%s %c %s :MODE cannot be set due to channel having an active MLOCK restriction policy",
                                                     channel->name.c_str(), *modes, mlock_str->c_str());