Skip to content
This repository
  • 2 commits
  • 1 file changed
  • 0 comments
  • 2 contributors
Jan 03, 2013
Robby cmode_b: Correction to the maxbans conditional
It was possible to set one more ban beyond the configured limit.
1aaba0d
Jan 05, 2013
Attila Molnar Merge pull request #397 from Robby-/insp20+cmode_b-limit
[2.0] cmode_b: Correction to the maxbans conditional
fd4b743

Showing 1 changed file with 1 addition and 1 deletion. Show diff stats Hide diff stats

  1. 2  src/modes/cmode_b.cpp
2  src/modes/cmode_b.cpp
@@ -116,7 +116,7 @@ std::string& ModeChannelBan::AddBan(User *user, std::string &dest, Channel *chan
116 116
 		return dest;
117 117
 
118 118
 	long maxbans = chan->GetMaxBans();
119  
-	if (IS_LOCAL(user) && ((unsigned)chan->bans.size() > (unsigned)maxbans))
  119
+	if (IS_LOCAL(user) && ((unsigned)chan->bans.size() >= (unsigned)maxbans))
120 120
 	{
121 121
 		user->WriteServ("478 %s %s :Channel ban list for %s is full (maximum entries for this channel is %ld)",user->nick.c_str(), chan->name.c_str(), chan->name.c_str(), maxbans);
122 122
 		dest.clear();

No commit comments for this range

Something went wrong with that request. Please try again.