summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-09-04 23:29:33 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-09-04 23:29:33 +0000
commit88e7c2cb0fc2e91f647a52dc6e274b3e3205743b (patch)
tree61165f6cf8eaaf5a0213e5ea38a7578151f16b70
parent9d5ac7988dc35df8a927e4984a979291be88c183 (diff)
Check for failover pointing at self. This is an obvious thing to check for and prevent :)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5142 e03df62e-2008-0410-955e-edbf42e46eb7
-rw-r--r--src/modules/m_spanningtree.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/modules/m_spanningtree.cpp b/src/modules/m_spanningtree.cpp
index 395644772..7ac65dbc3 100644
--- a/src/modules/m_spanningtree.cpp
+++ b/src/modules/m_spanningtree.cpp
@@ -4084,6 +4084,11 @@ class ModuleSpanningTree : public Module
{
if (x->FailOver.length())
{
+ if (x->FailOver == x->Name)
+ {
+ ServerInstance->SNO->WriteToSnoMask('l',"FAILOVER: Some muppet configured the failover for server \002%s\002 to point at itself. Not following it!", x->Name.c_str());
+ return;
+ }
Link* TryThisOne = this->FindLink(x->FailOver.c_str());
if (TryThisOne)
{