From 578b2b05b8f734217336b9dde35b47d52d96de34 Mon Sep 17 00:00:00 2001 From: Vladislav Vaintroub Date: Fri, 25 Aug 2017 16:14:03 +0000 Subject: MDEV-13641 host errors are not reset after successful connection. Fixed thd_set_peer_addr() to propagate host error count from ip_to_hostname() to check_connection(), which tests this count to clear errors affter successful authentication. --- sql/sql_connect.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'sql/sql_connect.h') diff --git a/sql/sql_connect.h b/sql/sql_connect.h index cd3650fb2b2..67950061da8 100644 --- a/sql/sql_connect.h +++ b/sql/sql_connect.h @@ -85,7 +85,10 @@ bool thd_init_client_charset(THD *thd, uint cs_number); bool setup_connection_thread_globals(THD *thd); bool thd_prepare_connection(THD *thd); bool thd_is_connection_alive(THD *thd); -int thd_set_peer_addr(THD *thd, sockaddr_storage *addr, const char *ip, uint port, bool check_proxy_networks); +int thd_set_peer_addr(THD *thd, sockaddr_storage *addr, + const char *ip, uint port, + bool check_proxy_networks, + uint *host_errors); bool login_connection(THD *thd); void prepare_new_connection_state(THD* thd); -- cgit v1.2.1