mysql_send_auth_error didn't check whether dcb is in DCB_STATE_POLLING state. If it is, function now returns.

This commit is contained in:
vraatikka 2013-11-21 15:35:55 +02:00
parent 4b2270727b
commit 323fb8164e

View File

@ -1172,6 +1172,17 @@ mysql_send_auth_error (DCB *dcb, int packet_number, int in_affected_rows, const
GWBUF *buf;
if (dcb->state != DCB_STATE_POLLING)
{
skygw_log_write(
LOGFILE_DEBUG,
"%lu [mysql_send_auth_error] dcb %p is in a state %s, "
"and it is not in epoll set anymore. Skip error sending.",
pthread_self(),
dcb,
STRDCBSTATE(dcb->state));
return 0;
}
mysql_errno = 1045;
mysql_error_msg = "Access denied!";
mysql_state = "2800";