MXS-1765: Update current command for KILL processing

The current command needs to be updated before the queries are actually
routed. This allows the KILL command detection and processing to correctly
work.
This commit is contained in:
Markus Mäkelä
2018-04-06 17:35:37 +03:00
parent 825d48fe05
commit 1e3ab1fc7c

View File

@ -972,6 +972,10 @@ gw_read_normal_data(DCB *dcb, GWBUF *read_buffer, int nbytes_read)
return 0;
}
// Update the current command, required by KILL command processing
MySQLProtocol *proto = (MySQLProtocol*)dcb->protocol;
proto->current_command = (mxs_mysql_cmd_t)mxs_mysql_get_command(read_buffer);
set_qc_mode(session, &read_buffer);
session_retain_statement(session, read_buffer);