summaryrefslogtreecommitdiff
path: root/src/modules/m_spanningtree/encap.cpp
diff options
context:
space:
mode:
authorAttila Molnar <attilamolnar@hush.com>2014-01-26 13:12:01 +0100
committerAttila Molnar <attilamolnar@hush.com>2014-01-26 13:12:01 +0100
commit3fef0ed889eecb40b96a597924254560c81d4a09 (patch)
tree78f1d41e26cd2b9f9a91442ef9ccc78683bad315 /src/modules/m_spanningtree/encap.cpp
parent92cc388aebd55245b24aef5950afe845feffe9e2 (diff)
Add ProtocolInterface::BroadcastEncap() and infrastructure for manually forwarding ENCAPs
Diffstat (limited to 'src/modules/m_spanningtree/encap.cpp')
-rw-r--r--src/modules/m_spanningtree/encap.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/modules/m_spanningtree/encap.cpp b/src/modules/m_spanningtree/encap.cpp
index 12ab2b664..566f15da8 100644
--- a/src/modules/m_spanningtree/encap.cpp
+++ b/src/modules/m_spanningtree/encap.cpp
@@ -27,8 +27,12 @@ CmdResult CommandEncap::Handle(User* user, std::vector<std::string>& params)
if (ServerInstance->Config->GetSID() == params[0] || InspIRCd::Match(ServerInstance->Config->ServerName, params[0]))
{
parameterlist plist(params.begin() + 2, params.end());
- ServerInstance->Parser->CallHandler(params[1], plist, user);
+ Command* cmd = NULL;
+ ServerInstance->Parser->CallHandler(params[1], plist, user, &cmd);
// Discard return value, ENCAP shall succeed even if the command does not exist
+
+ if ((cmd) && (cmd->force_manual_route))
+ return CMD_FAILURE;
}
return CMD_SUCCESS;
}