diff options
Diffstat (limited to 'extra/mariabackup')
-rw-r--r-- | extra/mariabackup/innobackupex.cc | 4 | ||||
-rw-r--r-- | extra/mariabackup/xbstream.cc | 7 | ||||
-rw-r--r-- | extra/mariabackup/xtrabackup.cc | 11 | ||||
-rw-r--r-- | extra/mariabackup/xtrabackup.h | 2 |
4 files changed, 13 insertions, 11 deletions
diff --git a/extra/mariabackup/innobackupex.cc b/extra/mariabackup/innobackupex.cc index 9e95d2e6b16..e874890ad27 100644 --- a/extra/mariabackup/innobackupex.cc +++ b/extra/mariabackup/innobackupex.cc @@ -88,7 +88,7 @@ char *opt_ibx_incremental_history_name = NULL; char *opt_ibx_incremental_history_uuid = NULL; char *opt_ibx_user = NULL; -char *opt_ibx_password = NULL; +const char *opt_ibx_password = NULL; char *opt_ibx_host = NULL; char *opt_ibx_defaults_group = NULL; char *opt_ibx_socket = NULL; @@ -731,7 +731,7 @@ indicates an error.\n"); static my_bool ibx_get_one_option(const struct my_option *opt, - char *argument, const char *) + const char *argument, const char *) { switch(opt->id) { case '?': diff --git a/extra/mariabackup/xbstream.cc b/extra/mariabackup/xbstream.cc index c22c7cc8f39..3fe9d17d86e 100644 --- a/extra/mariabackup/xbstream.cc +++ b/extra/mariabackup/xbstream.cc @@ -90,7 +90,7 @@ static int get_options(int *argc, char ***argv); static int mode_create(int argc, char **argv); static int mode_extract(int n_threads, int argc, char **argv); static my_bool get_one_option(const struct my_option *opt, - char *argument, const char *filename); + const char *argument, const char *filename); int main(int argc, char **argv) @@ -138,7 +138,8 @@ get_options(int *argc, char ***argv) int ho_error; if ((ho_error= handle_options(argc, argv, my_long_options, - get_one_option))) { + get_one_option))) + { exit(EXIT_FAILURE); } @@ -191,7 +192,7 @@ set_run_mode(run_mode_t mode) static my_bool -get_one_option(const struct my_option *opt, char *, const char *) +get_one_option(const struct my_option *opt, const char *, const char *) { switch (opt->id) { case 'c': diff --git a/extra/mariabackup/xtrabackup.cc b/extra/mariabackup/xtrabackup.cc index b8cdf4cd9db..495c7d7e2fe 100644 --- a/extra/mariabackup/xtrabackup.cc +++ b/extra/mariabackup/xtrabackup.cc @@ -311,7 +311,7 @@ char *opt_incremental_history_name; char *opt_incremental_history_uuid; char *opt_user; -char *opt_password; +const char *opt_password; char *opt_host; char *opt_defaults_group; char *opt_socket; @@ -1861,7 +1861,7 @@ check_if_param_set(const char *param) my_bool xb_get_one_option(const struct my_option *opt, - char *argument, const char *) + const char *argument, const char *) { switch(opt->id) { case 'h': @@ -6348,9 +6348,10 @@ void handle_options(int argc, char **argv, char ***argv_server, if (opt_password) { - char *argument= opt_password; - char *start= argument; - opt_password= my_strdup(PSI_NOT_INSTRUMENTED, opt_password, MYF(MY_FAE)); + char *argument= (char*) opt_password; + char *start= (char*) opt_password; + opt_password= my_strdup(PSI_NOT_INSTRUMENTED, opt_password, + MYF(MY_FAE)); while (*argument) *argument++= 'x'; // Destroy argument if (*start) diff --git a/extra/mariabackup/xtrabackup.h b/extra/mariabackup/xtrabackup.h index 6376849430c..aff7d1cb287 100644 --- a/extra/mariabackup/xtrabackup.h +++ b/extra/mariabackup/xtrabackup.h @@ -144,7 +144,7 @@ extern char *opt_incremental_history_name; extern char *opt_incremental_history_uuid; extern char *opt_user; -extern char *opt_password; +extern const char *opt_password; extern char *opt_host; extern char *opt_defaults_group; extern char *opt_socket; |