sql_parse.cc:

Add diagnostic printf to chack that number of connections for a user never drops below zero
This commit is contained in:
heikki@hundin.mysql.fi 2003-10-25 19:12:29 +03:00
parent f293edd19b
commit 5584d422ee

View File

@ -452,6 +452,9 @@ static void decrease_user_connections(USER_CONN *uc)
(void) pthread_mutex_lock(&LOCK_user_conn);
if (uc->connections == 0)
printf("Error: trying to decrease user %s connections below zero!\n",
uc->user);
if ((uc->connections && !--uc->connections) && !mqh_used)
{
/* Last connection for user; Delete it */