X-Git-Url: https://git.quassel-irc.org/?a=blobdiff_plain;f=src%2Fcore%2Fcoresession.cpp;h=5eed0eb01561d4fd32a20c2b1c3fb7006843a7e1;hb=145a52eb79fed146731f85c23b60f0609e40e785;hp=3c485f74820d870e6458cdac619aba06e96a1dd3;hpb=a95ad2de573027f9bee36db972bcae4195168d0c;p=quassel.git diff --git a/src/core/coresession.cpp b/src/core/coresession.cpp index 3c485f74..5eed0eb0 100644 --- a/src/core/coresession.cpp +++ b/src/core/coresession.cpp @@ -323,8 +323,18 @@ void CoreSession::recvMessageFromServer(RawMessage msg) // check for HardStrictness ignore CoreNetwork* currentNetwork = network(msg.networkId); QString networkName = currentNetwork ? currentNetwork->networkName() : QString(""); - if (_ignoreListManager.match(msg, networkName) == IgnoreListManager::HardStrictness) + switch (_ignoreListManager.match(msg, networkName)) { + case IgnoreListManager::StrictnessType::HardStrictness: + // Drop the message permanently return; + case IgnoreListManager::StrictnessType::SoftStrictness: + // Mark the message as (dynamically) ignored + msg.flags |= Message::Flag::Ignored; + break; + case IgnoreListManager::StrictnessType::UnmatchedStrictness: + // Keep the message unmodified + break; + } if (currentNetwork && _highlightRuleManager.match(msg, currentNetwork->myNick(), currentNetwork->identityPtr()->nicks())) msg.flags |= Message::Flag::Highlight; @@ -529,17 +539,11 @@ Protocol::SessionState CoreSession::sessionState() const /*** Identity Handling ***/ void CoreSession::createIdentity(const Identity& identity, const QVariantMap& additional) { -#ifndef HAVE_SSL - Q_UNUSED(additional) -#endif - CoreIdentity coreIdentity(identity); -#ifdef HAVE_SSL if (additional.contains("KeyPem")) coreIdentity.setSslKey(additional["KeyPem"].toByteArray()); if (additional.contains("CertPem")) coreIdentity.setSslCert(additional["CertPem"].toByteArray()); -#endif qDebug() << Q_FUNC_INFO; IdentityId id = Core::createIdentity(user(), coreIdentity); if (!id.isValid())