summaryrefslogtreecommitdiff
path: root/src/modules
diff options
context:
space:
mode:
authorw00t <w00t@e03df62e-2008-0410-955e-edbf42e46eb7>2007-08-27 03:14:06 +0000
committerw00t <w00t@e03df62e-2008-0410-955e-edbf42e46eb7>2007-08-27 03:14:06 +0000
commit95fdb54284dc6f3a1742e4fb4a2574bfc783626a (patch)
treef8679353abf186ba23670075d8a44bbcc255c2ba /src/modules
parentc24c23f50c95051b13b4d712f7e54117a6886974 (diff)
Make the server to server parser look for UUID. Currently it will fall back and try to find by nick too, to help catch legacy use of nickname prefixes. This will not be the case eventually.
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@7864 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules')
-rw-r--r--src/modules/m_spanningtree/treesocket2.cpp28
1 files changed, 24 insertions, 4 deletions
diff --git a/src/modules/m_spanningtree/treesocket2.cpp b/src/modules/m_spanningtree/treesocket2.cpp
index 83b8a8720..527f980bb 100644
--- a/src/modules/m_spanningtree/treesocket2.cpp
+++ b/src/modules/m_spanningtree/treesocket2.cpp
@@ -1414,10 +1414,30 @@ bool TreeSocket::ProcessLine(std::string &line)
}
else
{
- // not a special inter-server command.
- // Emulate the actual user doing the command,
- // this saves us having a huge ugly parser.
- userrec* who = this->Instance->FindNick(prefix);
+ /*
+ * Not a special s2s command. Emulate the user doing it.
+ * This saves us having a huge ugly command parser again.
+ */
+
+
+ /*
+ *
+ * First, let's find them by UID. If we don't find, try again
+ * by nick (to catch legacy commands temporarily).
+ * If we still don't .. carry on and pray. -- w00t
+ */
+ userrec *who = this->Instance->FindUUID(prefix);
+
+ if (!who)
+ {
+ userrec* who = this->Instance->FindNick(prefix);
+
+ if (who)
+ {
+ Instance->Log(DEBUG, "Glark! I got a legacy command!");
+ }
+ }
+
std::string sourceserv = this->myhost;
if (!this->InboundServerName.empty())
{