1
0
mirror of https://github.com/anope/anope.git synced 2026-06-27 18:26:39 +02:00

Check privilege name is valid in SetLevel

This commit is contained in:
Adam
2015-09-24 17:22:44 -04:00
parent 93a92bb73b
commit 830361e97d
+6
View File
@@ -576,6 +576,12 @@ int16_t ChannelInfo::GetLevel(const Anope::string &priv) const
void ChannelInfo::SetLevel(const Anope::string &priv, int16_t level)
{
if (PrivilegeManager::FindPrivilege(priv) == NULL)
{
Log(LOG_DEBUG) << "Unknown privilege " + priv;
return;
}
this->levels[priv] = level;
}