1 /* +------------------------------------+
2 * | Inspire Internet Relay Chat Daemon |
3 * +------------------------------------+
5 * InspIRCd: (C) 2002-2009 InspIRCd Development Team
6 * See: http://wiki.inspircd.org/Credits
8 * This program is free but copyrighted software; see
9 * the file COPYING for details.
11 * ---------------------------------------------------
17 #include "treesocket.h"
18 #include "treeserver.h"
21 /* $ModDep: m_spanningtree/utils.h m_spanningtree/treeserver.h m_spanningtree/treesocket.h */
25 /** remote MOTD. leet, huh? */
26 bool TreeSocket::Encap(const std::string &prefix, std::deque<std::string> ¶ms)
28 if (params.size() > 1)
30 if (InspIRCd::Match(ServerInstance->Config->GetSID(), params[0]))
32 Event event((char*) ¶ms, (Module*)this->Utils->Creator, "encap_received");
33 event.Send(ServerInstance);
36 params[params.size() - 1] = ":" + params[params.size() - 1];
38 if (params[0].find('*') != std::string::npos)
40 Utils->DoOneToAllButSender(prefix, "ENCAP", params, prefix);
43 Utils->DoOneToOne(prefix, "ENCAP", params, params[0]);