@@ -5406,6 +5406,7 @@ void create_thread_to_handle_connection(THD *thd)
5406
5406
mysql_mutex_unlock(&LOCK_connection_count);
5407
5407
5408
5408
statistic_increment(aborted_connects,&LOCK_status);
5409
+ statistic_increment(connection_internal_errors, &LOCK_status);
5409
5410
/* Can't use my_error() since store_globals has not been called. */
5410
5411
my_snprintf(error_message_buff, sizeof(error_message_buff),
5411
5412
ER_THD(thd, ER_CANT_CREATE_THREAD), error);
@@ -5414,7 +5415,6 @@ void create_thread_to_handle_connection(THD *thd)
5414
5415
mysql_mutex_lock(&LOCK_thread_count);
5415
5416
delete thd;
5416
5417
mysql_mutex_unlock(&LOCK_thread_count);
5417
- connection_internal_errors++;
5418
5418
return;
5419
5419
/* purecov: end */
5420
5420
}
@@ -5455,7 +5455,7 @@ static void create_new_thread(THD *thd)
5455
5455
DBUG_PRINT("error",("Too many connections"));
5456
5456
close_connection(thd, ER_CON_COUNT_ERROR);
5457
5457
delete thd;
5458
- connection_max_connection_errors++ ;
5458
+ statistic_increment( connection_max_connection_errors, &LOCK_status) ;
5459
5459
DBUG_VOID_RETURN;
5460
5460
}
5461
5461
@@ -5585,7 +5585,7 @@ void handle_connections_sockets()
5585
5585
There is not much details to report about the client,
5586
5586
increment the server global status variable.
5587
5587
*/
5588
- connection_select_errors++ ;
5588
+ statistic_increment( connection_select_errors, &LOCK_status) ;
5589
5589
if (!select_errors++ && !abort_loop) /* purecov: inspected */
5590
5590
sql_print_error("mysqld: Got error %d from select",socket_errno); /* purecov: inspected */
5591
5591
}
@@ -5667,7 +5667,7 @@ void handle_connections_sockets()
5667
5667
There is not much details to report about the client,
5668
5668
increment the server global status variable.
5669
5669
*/
5670
- connection_accept_errors++ ;
5670
+ statistic_increment( connection_accept_errors, &LOCK_status) ;
5671
5671
if ((error_count++ & 255) == 0) // This can happen often
5672
5672
sql_perror("Error in accept");
5673
5673
MAYBE_BROKEN_SYSCALL;
@@ -5710,7 +5710,7 @@ void handle_connections_sockets()
5710
5710
The connection was refused by TCP wrappers.
5711
5711
There are no details (by client IP) available to update the host_cache.
5712
5712
*/
5713
- connection_tcpwrap_errors++ ;
5713
+ statistic_increment( connection_tcpwrap_errors, &LOCK_status) ;
5714
5714
continue;
5715
5715
}
5716
5716
}
@@ -5725,7 +5725,7 @@ void handle_connections_sockets()
5725
5725
{
5726
5726
(void) mysql_socket_shutdown(new_sock, SHUT_RDWR);
5727
5727
(void) mysql_socket_close(new_sock);
5728
- connection_internal_errors++ ;
5728
+ statistic_increment( connection_internal_errors, &LOCK_status) ;
5729
5729
continue;
5730
5730
}
5731
5731
@@ -5750,7 +5750,7 @@ void handle_connections_sockets()
5750
5750
(void) mysql_socket_close(new_sock);
5751
5751
}
5752
5752
delete thd;
5753
- connection_internal_errors++ ;
5753
+ statistic_increment( connection_internal_errors, &LOCK_status) ;
5754
5754
continue;
5755
5755
}
5756
5756
init_net_server_extension(thd);
0 commit comments