From 67b482682e152f8bbec02580a2c3e5d3b1b0b138 Mon Sep 17 00:00:00 2001 From: w00t Date: Sat, 3 Jan 2009 17:25:10 +0000 Subject: Remove +o from users on deoper, plausible fix for bug #653 reported by Ankit. Let me know if it's still b0rked, please :) git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@10940 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/users.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/users.cpp b/src/users.cpp index 489028359..b884a4bc1 100644 --- a/src/users.cpp +++ b/src/users.cpp @@ -839,6 +839,7 @@ void User::UnOper() */ this->oper.clear(); + /* Remove all oper only modes from the user when the deoper - Bug #466*/ std::string moderemove("-"); @@ -849,12 +850,13 @@ void User::UnOper() moderemove += letter; } + std::vector parameters; parameters.push_back(this->nick); parameters.push_back(moderemove); ServerInstance->Parser->CallHandler("MODE", parameters, this); - + /* remove the user from the oper list. Will remove multiple entries as a safeguard against bug #404 */ ServerInstance->Users->all_opers.remove(this); @@ -872,6 +874,7 @@ void User::UnOper() AllowedUserModes.reset(); AllowedChanModes.reset(); + this->modes[UM_OPERATOR] = 0; } } -- cgit v1.2.3