Fix a logic bug with handling quits after the cleanup.

This commit is contained in:
Vlad Grigorescu 2014-10-31 16:24:48 -04:00
parent 119ad59b70
commit c601ebccb8

View file

@ -71,16 +71,13 @@ event mysql_command_request(c: connection, command: count, arg: string) &priorit
event mysql_command_request(c: connection, command: count, arg: string) &priority=-5
{
if ( !c?$mysql )
{
if ( command == 1 )
if ( c?$mysql && c$mysql?$cmd && c$mysql$cmd == "quit" )
{
# We get no response for quits, so let's just log it now.
Log::write(mysql::LOG, c$mysql);
delete c$mysql;
}
}
}
event mysql_error(c: connection, code: count, msg: string) &priority=5
{