mirror of
https://github.com/inspircd/inspircd.git
synced 2025-03-10 11:09:04 -04:00
Fix MySQL crash on module unload with empty query queue
This commit is contained in:
parent
e982cb765e
commit
13d719fe4c
@ -445,8 +445,10 @@ void ModuleSQL::OnUnloadModule(Module* mod)
|
||||
{
|
||||
SQLerror err(SQL_BAD_DBID);
|
||||
Dispatcher->LockQueue();
|
||||
for(unsigned int i = qq.size() - 1; i >= 0; i--)
|
||||
unsigned int i = qq.size();
|
||||
while (i > 0)
|
||||
{
|
||||
i--;
|
||||
if (qq[i].q->creator == mod)
|
||||
{
|
||||
if (i == 0)
|
||||
|
Loading…
x
Reference in New Issue
Block a user