From d572f1a67dbe8979f616cd2451b11a422cce0ade Mon Sep 17 00:00:00 2001 From: Attila Molnar Date: Mon, 28 Jul 2014 14:48:50 +0200 Subject: m_spanningtree Throw a ProtocolException if a server SQUITs a server it shouldn't --- src/modules/m_spanningtree/treesocket1.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src') diff --git a/src/modules/m_spanningtree/treesocket1.cpp b/src/modules/m_spanningtree/treesocket1.cpp index 4e738488b..1a8bdd06c 100644 --- a/src/modules/m_spanningtree/treesocket1.cpp +++ b/src/modules/m_spanningtree/treesocket1.cpp @@ -154,6 +154,8 @@ CmdResult CommandSQuit::HandleServer(TreeServer* server, std::vectorGetParent(); } + else if (quitting->GetParent() != server) + throw ProtocolException("Attempted to SQUIT a non-directly connected server or the parent"); server->SQuitChild(quitting, params[1]); -- cgit v1.2.3