summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAttila Molnar <attilamolnar@hush.com>2016-03-29 12:50:00 +0200
committerAttila Molnar <attilamolnar@hush.com>2016-03-29 12:50:00 +0200
commitda2b0ee6cad139804442a1ebcd0448755714f22a (patch)
tree124b8672875539c7212d3920cff33e2ea676d564 /src
parentea258053f694ff17980e2f39ea182f3a2de9ba5b (diff)
m_spanningtree Use SpanningTreeUtilities::FindRouteTarget() in RouteCommand()
This makes ROUTE_UNICAST() accept nicks and uuids
Diffstat (limited to 'src')
-rw-r--r--src/modules/m_spanningtree/postcommand.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/modules/m_spanningtree/postcommand.cpp b/src/modules/m_spanningtree/postcommand.cpp
index ae98be946..7b0478229 100644
--- a/src/modules/m_spanningtree/postcommand.cpp
+++ b/src/modules/m_spanningtree/postcommand.cpp
@@ -51,7 +51,9 @@ void SpanningTreeUtilities::RouteCommand(TreeServer* origin, CommandBase* thiscm
sdest = static_cast<TreeServer*>(routing.server);
if (!sdest)
{
- sdest = FindServer(routing.serverdest);
+ // Assume the command handler already validated routing.serverdest and have only returned success if the target is something that the
+ // user executing the command is allowed to look up e.g. target is not an uuid if user is local.
+ sdest = FindRouteTarget(routing.serverdest);
if (!sdest)
{
ServerInstance->Logs->Log(MODNAME, LOG_DEFAULT, "Trying to route %s%s to nonexistant server %s", (encap ? "ENCAP " : ""), command.c_str(), routing.serverdest.c_str());