mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
MDEV-26221: DYNAMIC_ARRAY use size_t for sizes
https://jira.mariadb.org/browse/MDEV-26221 my_sys DYNAMIC_ARRAY and DYNAMIC_STRING inconsistancy The DYNAMIC_STRING uses size_t for sizes, but DYNAMIC_ARRAY used uint. This patch adjusts DYNAMIC_ARRAY to use size_t like DYNAMIC_STRING. As the MY_DIR member number_of_files is copied from a DYNAMIC_ARRAY, this is changed to be size_t. As MY_TMPDIR members 'cur' and 'max' are copied from a DYNAMIC_ARRAY, these are also changed to be size_t. The lists of plugins and stored procedures use DYNAMIC_ARRAY, but their APIs assume a size of 'uint'; these are unchanged.
This commit is contained in:
committed by
Vicențiu-Marian Ciorbaru
parent
9ab0d07e10
commit
401ff6994d
@ -8934,7 +8934,7 @@ fill_record_n_invoke_before_triggers(THD *thd, TABLE *table, Field **ptr,
|
||||
|
||||
my_bool mysql_rm_tmp_tables(void)
|
||||
{
|
||||
uint i, idx;
|
||||
size_t i, idx;
|
||||
char path[FN_REFLEN], *tmpdir, path_copy[FN_REFLEN];
|
||||
MY_DIR *dirp;
|
||||
FILEINFO *file;
|
||||
@ -8956,7 +8956,7 @@ my_bool mysql_rm_tmp_tables(void)
|
||||
|
||||
/* Remove all SQLxxx tables from directory */
|
||||
|
||||
for (idx=0 ; idx < (uint) dirp->number_of_files ; idx++)
|
||||
for (idx=0 ; idx < dirp->number_of_files ; idx++)
|
||||
{
|
||||
file=dirp->dir_entry+idx;
|
||||
|
||||
|
Reference in New Issue
Block a user