diff options
author | Adam <Adam@anope.org> | 2013-07-04 01:19:40 -0400 |
---|---|---|
committer | Adam <Adam@anope.org> | 2013-07-04 01:19:40 -0400 |
commit | 998925c90a7ffa3dc6c4bf715699565dac49c10c (patch) | |
tree | 355d1dbe3c86ca08e61976baa905bb3cd30264aa /modules/extra/m_mysql.cpp | |
parent | 7f971043bc0b552e0ec2f3a88bf123cecb007387 (diff) |
Fix rehashing via SIGHUP and m_mysql
Diffstat (limited to 'modules/extra/m_mysql.cpp')
-rw-r--r-- | modules/extra/m_mysql.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/extra/m_mysql.cpp b/modules/extra/m_mysql.cpp index 3b8715c52..79198a814 100644 --- a/modules/extra/m_mysql.cpp +++ b/modules/extra/m_mysql.cpp @@ -189,7 +189,7 @@ class ModuleSQL : public Module, public Pipe void OnReload(Configuration::Conf *conf) anope_override { Configuration::Block *config = Config->GetModule(this); - int i, num; + int i; for (std::map<Anope::string, MySQLService *>::iterator it = this->MySQLServices.begin(); it != this->MySQLServices.end();) { @@ -201,7 +201,7 @@ class ModuleSQL : public Module, public Pipe if (Config->GetBlock("mysql", i)->Get<const Anope::string>("name", "main") == cname) break; - if (i == num) + if (i == Config->CountBlock("mysql")) { Log(LOG_NORMAL, "mysql") << "MySQL: Removing server connection " << cname; |