From 503eb42e404352f5e101f9658749f095a0160591 Mon Sep 17 00:00:00 2001 From: Adam Date: Tue, 15 Nov 2011 16:30:31 -0500 Subject: [PATCH] Made looking up a level for a nonexistant privilege debugg log a warning, not abort --- src/regchannel.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/regchannel.cpp b/src/regchannel.cpp index a7a2e2c22..660233d2b 100644 --- a/src/regchannel.cpp +++ b/src/regchannel.cpp @@ -1032,7 +1032,10 @@ void ChannelInfo::RestoreTopic() int16_t ChannelInfo::GetLevel(const Anope::string &priv) { if (PrivilegeManager::FindPrivilege(priv) == NULL) - throw CoreException("Unknown privilege " + priv); + { + Log(LOG_DEBUG) << "Unknown privilege " + priv; + return ACCESS_INVALID; + } if (this->levels.count(priv) == 0) this->levels[priv] = 0;