EQEmulator Forums

EQEmulator Forums (https://www.eqemulator.org/forums/index.php)
-   Development::Server Code Submissions (https://www.eqemulator.org/forums/forumdisplay.php?f=669)
-   -   Submission: IP Limiting Minor Fix (https://www.eqemulator.org/forums/showthread.php?t=26318)

trevius 09-24-2008 08:02 PM

Submission: IP Limiting Minor Fix
 
I noticed that setting the exempt status for accounts doesn't actually work to make that status exempt in the current version of IP Limiting. You have to set it 1 higher status on the account than what you set the rule to for it to be exempt. This is misleading and not how I think it is supposed to work. The reason is here in RED:

world/clientlist.cpp
Code:

                if ((countCLEIPs->GetIP() == iIP) && ((countCLEIPs->Admin() <= (RuleI(World, ExemptMaxClientsStatus))) || (RuleI(World, ExemptMaxClientsStatus) < 0))) {

And I believe the fix is simple. Just change the <= into a < as shown here in RED:
Code:

                if ((countCLEIPs->GetIP() == iIP) && ((countCLEIPs->Admin() < (RuleI(World, ExemptMaxClientsStatus))) || (RuleI(World, ExemptMaxClientsStatus) < 0))) {
That is a pretty minor fix, but a valid one IMO.


All times are GMT -4. The time now is 06:49 PM.

Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.