Add exception handling here

git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@4361 e03df62e-2008-0410-955e-edbf42e46eb7
This commit is contained in:
brain 2006-07-12 13:01:06 +00:00
parent 45fe5e1683
commit 4917b48d84

View File

@ -55,8 +55,16 @@ class cmd_woot : public command_t
{
/* We dont have to worry about deleting 'r', the core will
* do it for us as required.*/
MyResolver* r = new MyResolver("brainbox.ath.cx", true);
Srv->AddResolver(r);
try
{
MyResolver* r = new MyResolver("brainbox.ath.cx", true);
Srv->AddResolver(r);
}
catch (ModuleException& e)
{
log(DEBUG,"Danger, will robinson! There was an exception: %s",e.GetReason());
}
}
};