summaryrefslogtreecommitdiff
path: root/src/modules/m_spanningtree
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2008-09-21 12:17:31 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2008-09-21 12:17:31 +0000
commitbe609949e3ec2543d6cb16d23240870028732f36 (patch)
tree2f55fa5ed596ac1b2f6c9322fb883ec2d8ee99c5 /src/modules/m_spanningtree
parentce6764c87f83c3a74aae0fcd75547a368601b14a (diff)
Fix various rline bugs, implement /stats R, and fix the issue where you get no error. "Something will already have said why it fucked up" -- what
about when the rline fails due to missing provider? Also fix the fact that we dont have a catch around the Generate() in addline, which would just make insp abort. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@10577 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules/m_spanningtree')
-rw-r--r--src/modules/m_spanningtree/addline.cpp11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/modules/m_spanningtree/addline.cpp b/src/modules/m_spanningtree/addline.cpp
index b9bca3109..dde9f45d3 100644
--- a/src/modules/m_spanningtree/addline.cpp
+++ b/src/modules/m_spanningtree/addline.cpp
@@ -47,7 +47,16 @@ bool TreeSocket::AddLine(const std::string &prefix, std::deque<std::string> &par
return true;
}
- XLine* xl = xlf->Generate(Instance->Time(), atoi(params[4].c_str()), params[2].c_str(), params[5].c_str(), params[1].c_str());
+ XLine* xl = NULL;
+ try
+ {
+ xl = xlf->Generate(Instance->Time(), atoi(params[4].c_str()), params[2].c_str(), params[5].c_str(), params[1].c_str());
+ }
+ catch (ModuleException &e)
+ {
+ this->Instance->SNO->WriteToSnoMask('x',"Unable to ADDLINE type %s from %s: %s", params[0].c_str(), setter.c_str(), e.GetReason());
+ return true;
+ }
xl->SetCreateTime(atoi(params[3].c_str()));
if (Instance->XLines->AddLine(xl,NULL))
{