We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b3dbf43 commit 2cc35d8Copy full SHA for 2cc35d8
src/modules/extra/m_mysql.cpp
@@ -380,6 +380,9 @@ ModuleSQL::ModuleSQL()
380
381
void ModuleSQL::init()
382
{
383
+ if (mysql_library_init(0, NULL, NULL))
384
+ throw ModuleException("Unable to initialise the MySQL library!");
385
+
386
Dispatcher = new DispatcherThread(this);
387
ServerInstance->Threads->Start(Dispatcher);
388
@@ -397,10 +400,13 @@ ModuleSQL::~ModuleSQL()
397
400
Dispatcher->OnNotify();
398
401
delete Dispatcher;
399
402
}
403
404
for(ConnMap::iterator i = connections.begin(); i != connections.end(); i++)
405
406
delete i->second;
407
408
409
+ mysql_library_end();
410
411
412
void ModuleSQL::OnRehash(User* user)
0 commit comments