summaryrefslogtreecommitdiff
path: root/src/users.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-02-19 14:44:32 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-02-19 14:44:32 +0000
commit2a9b0cdd30113ab4926f4b68350d619c015c89a3 (patch)
treec756e270ca7d938d62d09c2ecee9d7c6be34af50 /src/users.cpp
parent45fa01dc79889c68734a7629e8487917cf26a836 (diff)
Added exception handling for module loading
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3240 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/users.cpp')
-rw-r--r--src/users.cpp18
1 files changed, 16 insertions, 2 deletions
diff --git a/src/users.cpp b/src/users.cpp
index 15663a7d1..f2aa4950f 100644
--- a/src/users.cpp
+++ b/src/users.cpp
@@ -409,7 +409,14 @@ void kill_link(userrec *user,const char* r)
{
if (Config->GetIOHook(user->port))
{
- Config->GetIOHook(user->port)->OnRawSocketClose(user->fd);
+ try
+ {
+ Config->GetIOHook(user->port)->OnRawSocketClose(user->fd);
+ }
+ catch (ModuleException modexcept)
+ {
+ log(DEBUG,"Module exception cought: %s",modexcept.GetReason()); \
+ }
}
ServerInstance->SE->DelFd(user->fd);
user->CloseSocket();
@@ -472,7 +479,14 @@ void kill_link_silent(userrec *user,const char* r)
{
if (Config->GetIOHook(user->port))
{
- Config->GetIOHook(user->port)->OnRawSocketClose(user->fd);
+ try
+ {
+ Config->GetIOHook(user->port)->OnRawSocketClose(user->fd);
+ }
+ catch (ModuleException modexcept)
+ {
+ log(DEBUG,"Module exception cought: %s",modexcept.GetReason()); \
+ }
}
ServerInstance->SE->DelFd(user->fd);
user->CloseSocket();