Backport r8786 from dz: closes bug #391

git-svn-id: http://svn.inspircd.org/repository/branches/1_1_stable@8787 e03df62e-2008-0410-955e-edbf42e46eb7
This commit is contained in:
w00t 2008-02-02 12:43:36 +00:00
parent cae7bae1ce
commit 97661ac20d
2 changed files with 12 additions and 6 deletions

View File

@ -113,9 +113,6 @@ class ModuleSSLGnuTLS : public Module
virtual void OnRehash(userrec* user, const std::string &param)
{
if(param != "ssl")
return;
Conf = new ConfigReader(ServerInstance);
for(unsigned int i = 0; i < listenports.size(); i++)
@ -164,6 +161,12 @@ class ModuleSSLGnuTLS : public Module
}
}
if(param != "ssl")
{
delete Conf;
return;
}
std::string confdir(ServerInstance->ConfigFileName);
// +1 so we the path ends with a /
confdir = confdir.substr(0, confdir.find_last_of('/') + 1);

View File

@ -157,9 +157,6 @@ class ModuleSSLOpenSSL : public Module
virtual void OnRehash(userrec* user, const std::string &param)
{
if (param != "ssl")
return;
Conf = new ConfigReader(ServerInstance);
for (unsigned int i = 0; i < listenports.size(); i++)
@ -211,6 +208,12 @@ class ModuleSSLOpenSSL : public Module
if (!sslports.empty())
sslports.erase(sslports.end() - 1);
if (param != "ssl")
{
delete Conf;
return;
}
std::string confdir(ServerInstance->ConfigFileName);
// +1 so we the path ends with a /
confdir = confdir.substr(0, confdir.find_last_of('/') + 1);