mirror of
https://github.com/MariaDB/server.git
synced 2025-08-01 03:47:19 +03:00
Fixed bug in counting open files when using many files
Fixed bug in JOIN
This commit is contained in:
@ -75,8 +75,8 @@ int my_close(File fd, myf MyFlags)
|
||||
pthread_mutex_destroy(&my_file_info[fd].mutex);
|
||||
#endif
|
||||
my_file_info[fd].type = UNOPEN;
|
||||
my_file_opened--;
|
||||
}
|
||||
my_file_opened--;
|
||||
pthread_mutex_unlock(&THR_LOCK_open);
|
||||
DBUG_RETURN(err);
|
||||
} /* my_close */
|
||||
@ -96,9 +96,8 @@ File my_register_filename(File fd, const char *FileName, enum file_type
|
||||
my_error(EE_OUT_OF_FILERESOURCES, MYF(ME_BELL+ME_WAITTANG),
|
||||
FileName, my_errno);
|
||||
return(-1);
|
||||
#else
|
||||
thread_safe_increment(my_file_opened,&THR_LOCK_open);
|
||||
#endif
|
||||
thread_safe_increment(my_file_opened,&THR_LOCK_open);
|
||||
return(fd); /* safeguard */
|
||||
}
|
||||
pthread_mutex_lock(&THR_LOCK_open);
|
||||
|
Reference in New Issue
Block a user