]> git.netwichtig.de Git - user/henk/code/inspircd.git/commitdiff
Added warnings to opers when session limits are exceeded
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>
Fri, 27 Jan 2006 15:32:57 +0000 (15:32 +0000)
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>
Fri, 27 Jan 2006 15:32:57 +0000 (15:32 +0000)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2935 e03df62e-2008-0410-955e-edbf42e46eb7

src/users.cpp

index 8089f5c235fc0e4bc9959dc114dcca8189319d01..0724372100e5b480c1ae3a68dfb61156d1956087 100644 (file)
@@ -728,11 +728,13 @@ void FullConnectUser(userrec* user, CullList* Goners)
        if (FindMatchingLocal(user) > a.maxlocal)
        {
                Goners->AddItem(user,"No more connections allowed from your host via this connect class (local)");
+               WriteOpers("*** WARNING: maximum LOCAL connections (%ld) exceeded for IP %s",a.maxlocal,(char*)inet_ntoa(user->ip4));
                return;
        }
-       if (FindMatchingGlobal(user) > a.maxglobal)
+       else if (FindMatchingGlobal(user) > a.maxglobal)
        {
                Goners->AddItem(user,"No more connections allowed from your host via this connect class (global)");
+               WriteOpers("*** WARNING: maximum GLOBAL connections (%ld) exceeded for IP %s",a.maxglobal,(char*)inet_ntoa(user->ip4));
                return;
        }