summaryrefslogtreecommitdiff
path: root/client/mysqlcheck.c
diff options
context:
space:
mode:
Diffstat (limited to 'client/mysqlcheck.c')
-rw-r--r--client/mysqlcheck.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/client/mysqlcheck.c b/client/mysqlcheck.c
index 86e1b3352b4..d2edd084c57 100644
--- a/client/mysqlcheck.c
+++ b/client/mysqlcheck.c
@@ -349,7 +349,7 @@ static int get_options(int *argc, char ***argv)
if (!what_to_do)
{
- int pnlen = strlen(my_progname);
+ size_t pnlen= strlen(my_progname);
if (pnlen < 6) /* name too short */
what_to_do = DO_CHECK;
@@ -448,7 +448,8 @@ static int process_selected_tables(char *db, char **table_names, int tables)
space is for more readable output in logs and in case of error
*/
char *table_names_comma_sep, *end;
- int i, tot_length = 0;
+ size_t tot_length= 0;
+ int i= 0;
for (i = 0; i < tables; i++)
tot_length+= fixed_name_length(*(table_names + i)) + 2;
@@ -464,7 +465,7 @@ static int process_selected_tables(char *db, char **table_names, int tables)
*end++= ',';
}
*--end = 0;
- handle_request_for_tables(table_names_comma_sep + 1, tot_length - 1);
+ handle_request_for_tables(table_names_comma_sep + 1, (uint) (tot_length - 1));
my_free(table_names_comma_sep, MYF(0));
}
else
@@ -486,7 +487,7 @@ static uint fixed_name_length(const char *name)
else if (*p == '.')
extra_length+= 2;
}
- return (p - name) + extra_length;
+ return (uint) ((p - name) + extra_length);
}