1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00
This commit is contained in:
serg@serg.mylan
2006-01-04 10:36:49 +01:00
parent 533b18c8f9
commit 8241a5a8e8
5 changed files with 18 additions and 18 deletions

View File

@ -6642,17 +6642,14 @@ static void refresh_status(void)
{
pthread_mutex_lock(&LOCK_status);
for (struct show_var_st *ptr=status_vars; ptr->name; ptr++)
{
if (ptr->type == SHOW_LONG)
if (ptr->type == SHOW_LONG) // note that SHOW_LONG_NOFLUSH variables are not reset
*(ulong*) ptr->value= 0;
else if (ptr->type == SHOW_LONG_STATUS)
{
THD *thd= current_thd;
/* We must update the global status before cleaning up the thread */
add_to_status(&global_status_var, &thd->status_var);
bzero((char*) &thd->status_var, sizeof(thd->status_var));
}
}
/* We must update the global status before cleaning up the thread */
THD *thd= current_thd;
add_to_status(&global_status_var, &thd->status_var);
bzero((char*) &thd->status_var, sizeof(thd->status_var));
/* Reset the counters of all key caches (default and named). */
process_key_caches(reset_key_cache_counters);
pthread_mutex_unlock(&LOCK_status);