summaryrefslogtreecommitdiff
path: root/src/inspircd_io.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-02-19 20:46:35 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-02-19 20:46:35 +0000
commit484cb43c21aafa489634f9137428da8c5a8461b1 (patch)
treef3e9f9fe242b8fa0e07a6e25a246dfc289c4948d /src/inspircd_io.cpp
parentc1f1f982e8af92f633db150a26caa8b4d1fbdb01 (diff)
Throws exception on failed GetIOHook()
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3257 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/inspircd_io.cpp')
-rw-r--r--src/inspircd_io.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/inspircd_io.cpp b/src/inspircd_io.cpp
index 5995115f5..f1be7bc22 100644
--- a/src/inspircd_io.cpp
+++ b/src/inspircd_io.cpp
@@ -82,7 +82,12 @@ bool ServerConfig::AddIOHook(int port, Module* iomod)
IOHookModule[port] = iomod;
return true;
}
- return false;
+ else
+ {
+ ModuleException err("Port already hooked by another module");
+ throw(err);
+ return false;
+ }
}
bool ServerConfig::DelIOHook(int port)
@@ -259,7 +264,7 @@ void ServerConfig::Read(bool bail, userrec* user)
Config->dns_timeout = atoi(DNT);
if (!strchr(Config->ServerName,'.'))
{
- log(DEFAULT,"WARNING: <server:name> '%s' is not a fully-qualified domain name. Changed to '%s\.'",Config->ServerName,Config->ServerName);
+ log(DEFAULT,"WARNING: <server:name> '%s' is not a fully-qualified domain name. Changed to '%s%c'",Config->ServerName,Config->ServerName,'.');
strlcat(Config->ServerName,".",MAXBUF);
}
if (!Config->dns_timeout)